home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 January: Mac OS SDK / Dev.CD Jan 99 SDK1.toast / Development Kits / Interfaces&Libraries / Universal / Interfaces / CIncludes / ImageCompression.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-08-17  |  69.4 KB  |  1,835 lines  |  [TEXT/MPS ]

  1. /*
  2.      File:        ImageCompression.h
  3.  
  4.      Contains:    QuickTime Image Compression Interfaces.
  5.  
  6.      Version:    Technology:    QuickTime 3.0
  7.                  Release:    Universal Interfaces 3.2
  8.  
  9.      Copyright:    © 1990-1998 by Apple Computer, Inc., all rights reserved
  10.  
  11.      Bugs?:        For bug reports, consult the following page on
  12.                  the World Wide Web:
  13.  
  14.                      http://developer.apple.com/bugreporter/
  15.  
  16. */
  17. #ifndef __IMAGECOMPRESSION__
  18. #define __IMAGECOMPRESSION__
  19.  
  20. #ifndef __MACTYPES__
  21. #include <MacTypes.h>
  22. #endif
  23. #ifndef __QUICKDRAW__
  24. #include <Quickdraw.h>
  25. #endif
  26. #ifndef __QDOFFSCREEN__
  27. #include <QDOffscreen.h>
  28. #endif
  29. #ifndef __COMPONENTS__
  30. #include <Components.h>
  31. #endif
  32. #ifndef __STANDARDFILE__
  33. #include <StandardFile.h>
  34. #endif
  35.  
  36.  
  37.  
  38. #if PRAGMA_ONCE
  39. #pragma once
  40. #endif
  41.  
  42. #ifdef __cplusplus
  43. extern "C" {
  44. #endif
  45.  
  46. #if PRAGMA_IMPORT
  47. #pragma import on
  48. #endif
  49.  
  50. #if PRAGMA_STRUCT_ALIGN
  51.     #pragma options align=mac68k
  52. #elif PRAGMA_STRUCT_PACKPUSH
  53.     #pragma pack(push, 2)
  54. #elif PRAGMA_STRUCT_PACK
  55.     #pragma pack(2)
  56. #endif
  57.  
  58.  
  59. struct MatrixRecord {
  60.     Fixed                             matrix[3][3];
  61. };
  62. typedef struct MatrixRecord                MatrixRecord;
  63. typedef MatrixRecord *                    MatrixRecordPtr;
  64.  
  65.  
  66. struct FixedPoint {
  67.     Fixed                             x;
  68.     Fixed                             y;
  69. };
  70. typedef struct FixedPoint                FixedPoint;
  71.  
  72.  
  73. struct FixedRect {
  74.     Fixed                             left;
  75.     Fixed                             top;
  76.     Fixed                             right;
  77.     Fixed                             bottom;
  78. };
  79. typedef struct FixedRect                FixedRect;
  80.  
  81. enum {
  82.     kRawCodecType                = FOUR_CHAR_CODE('raw '),
  83.     kCinepakCodecType            = FOUR_CHAR_CODE('cvid'),
  84.     kGraphicsCodecType            = FOUR_CHAR_CODE('smc '),
  85.     kAnimationCodecType            = FOUR_CHAR_CODE('rle '),
  86.     kVideoCodecType                = FOUR_CHAR_CODE('rpza'),
  87.     kComponentVideoCodecType    = FOUR_CHAR_CODE('yuv2'),
  88.     kJPEGCodecType                = FOUR_CHAR_CODE('jpeg'),
  89.     kMotionJPEGACodecType        = FOUR_CHAR_CODE('mjpa'),
  90.     kMotionJPEGBCodecType        = FOUR_CHAR_CODE('mjpb'),
  91.     kSGICodecType                = FOUR_CHAR_CODE('.SGI'),
  92.     kPlanarRGBCodecType            = FOUR_CHAR_CODE('8BPS'),
  93.     kMacPaintCodecType            = FOUR_CHAR_CODE('PNTG'),
  94.     kGIFCodecType                = FOUR_CHAR_CODE('gif '),
  95.     kPhotoCDCodecType            = FOUR_CHAR_CODE('kpcd'),
  96.     kQuickDrawGXCodecType        = FOUR_CHAR_CODE('qdgx'),
  97.     kAVRJPEGCodecType            = FOUR_CHAR_CODE('avr '),
  98.     kOpenDMLJPEGCodecType        = FOUR_CHAR_CODE('dmb1'),
  99.     kBMPCodecType                = FOUR_CHAR_CODE('WRLE'),
  100.     kWindowsRawCodecType        = FOUR_CHAR_CODE('WRAW'),
  101.     kVectorCodecType            = FOUR_CHAR_CODE('path'),
  102.     kQuickDrawCodecType            = FOUR_CHAR_CODE('qdrw'),
  103.     kWaterRippleCodecType        = FOUR_CHAR_CODE('ripl'),
  104.     kFireCodecType                = FOUR_CHAR_CODE('fire'),
  105.     kCloudCodecType                = FOUR_CHAR_CODE('clou'),
  106.     kH261CodecType                = FOUR_CHAR_CODE('h261'),
  107.     kH263CodecType                = FOUR_CHAR_CODE('h263'),
  108.     kDVCNTSCCodecType            = FOUR_CHAR_CODE('dvc '),
  109.     kDVCPALCodecType            = FOUR_CHAR_CODE('dvcp'),
  110.     kDVCProNTSCCodecType        = FOUR_CHAR_CODE('dvpn'),
  111.     kDVCProPALCodecType            = FOUR_CHAR_CODE('dvpp'),
  112.     kBaseCodecType                = FOUR_CHAR_CODE('base'),
  113.     kFLCCodecType                = FOUR_CHAR_CODE('flic'),
  114.     kTargaCodecType                = FOUR_CHAR_CODE('tga '),        /*    NOTE: despite what might seem obvious from the two constants*/
  115.                                                                 /*    below and their names, they really are correct. 'yuvu' really */
  116.                                                                 /*    does mean signed, and 'yuvs' really does mean unsigned. Really. */
  117.     kComponentVideoSigned        = FOUR_CHAR_CODE('yuvu'),
  118.     kComponentVideoUnsigned        = FOUR_CHAR_CODE('yuvs'),
  119.     kCMYKCodecType                = FOUR_CHAR_CODE('cmyk'),
  120.     kMicrosoftVideo1CodecType    = FOUR_CHAR_CODE('msvc'),
  121.     kSorensonCodecType            = FOUR_CHAR_CODE('SVQ1'),
  122.     kIndeo4CodecType            = FOUR_CHAR_CODE('IV41')
  123. };
  124.  
  125.  
  126. /* one source effects */
  127.  
  128. enum {
  129.     kBlurImageFilterType        = FOUR_CHAR_CODE('blur'),
  130.     kSharpenImageFilterType        = FOUR_CHAR_CODE('shrp'),
  131.     kEdgeDetectImageFilterType    = FOUR_CHAR_CODE('edge'),
  132.     kEmbossImageFilterType        = FOUR_CHAR_CODE('embs'),
  133.     kConvolveImageFilterType    = FOUR_CHAR_CODE('genk'),
  134.     kAlphaGainImageFilterType    = FOUR_CHAR_CODE('gain'),
  135.     kRGBColorBalanceImageFilterType = FOUR_CHAR_CODE('rgbb'),
  136.     kHSLColorBalanceImageFilterType = FOUR_CHAR_CODE('hslb'),
  137.     kColorSyncImageFilterType    = FOUR_CHAR_CODE('sync'),
  138.     kFilmNoiseImageFilterType    = FOUR_CHAR_CODE('fmns'),
  139.     kSolarizeImageFilterType    = FOUR_CHAR_CODE('solr'),
  140.     kColorTintImageFilterType    = FOUR_CHAR_CODE('tint')
  141. };
  142.  
  143. /* two source effects */
  144.  
  145. enum {
  146.     kAlphaCompositorTransitionType = FOUR_CHAR_CODE('blnd'),
  147.     kCrossFadeTransitionType    = FOUR_CHAR_CODE('dslv'),
  148.     kChromaKeyTransitionType    = FOUR_CHAR_CODE('ckey'),
  149.     kImplodeTransitionType        = FOUR_CHAR_CODE('mplo'),
  150.     kExplodeTransitionType        = FOUR_CHAR_CODE('xplo'),
  151.     kGradientTransitionType        = FOUR_CHAR_CODE('matt'),
  152.     kPushTransitionType            = FOUR_CHAR_CODE('push'),
  153.     kSlideTransitionType        = FOUR_CHAR_CODE('slid'),
  154.     kWipeTransitionType            = FOUR_CHAR_CODE('smpt'),
  155.     kIrisTransitionType            = FOUR_CHAR_CODE('smp2'),
  156.     kRadialTransitionType        = FOUR_CHAR_CODE('smp3'),
  157.     kMatrixTransitionType        = FOUR_CHAR_CODE('smp4')
  158. };
  159.  
  160. /* These are the bits that are set in the Component flags, and also in the codecInfo struct. */
  161.  
  162. enum {
  163.     codecInfoDoes1                = (1L << 0),                    /* codec can work with 1-bit pixels */
  164.     codecInfoDoes2                = (1L << 1),                    /* codec can work with 2-bit pixels */
  165.     codecInfoDoes4                = (1L << 2),                    /* codec can work with 4-bit pixels */
  166.     codecInfoDoes8                = (1L << 3),                    /* codec can work with 8-bit pixels */
  167.     codecInfoDoes16                = (1L << 4),                    /* codec can work with 16-bit pixels */
  168.     codecInfoDoes32                = (1L << 5),                    /* codec can work with 32-bit pixels */
  169.     codecInfoDoesDither            = (1L << 6),                    /* codec can do ditherMode */
  170.     codecInfoDoesStretch        = (1L << 7),                    /* codec can stretch to arbitrary sizes */
  171.     codecInfoDoesShrink            = (1L << 8),                    /* codec can shrink to arbitrary sizes */
  172.     codecInfoDoesMask            = (1L << 9),                    /* codec can mask to clipping regions */
  173.     codecInfoDoesTemporal        = (1L << 10),                    /* codec can handle temporal redundancy */
  174.     codecInfoDoesDouble            = (1L << 11),                    /* codec can stretch to double size exactly */
  175.     codecInfoDoesQuad            = (1L << 12),                    /* codec can stretch to quadruple size exactly */
  176.     codecInfoDoesHalf            = (1L << 13),                    /* codec can shrink to half size */
  177.     codecInfoDoesQuarter        = (1L << 14),                    /* codec can shrink to quarter size */
  178.     codecInfoDoesRotate            = (1L << 15),                    /* codec can rotate on decompress */
  179.     codecInfoDoesHorizFlip        = (1L << 16),                    /* codec can flip horizontally on decompress */
  180.     codecInfoDoesVertFlip        = (1L << 17),                    /* codec can flip vertically on decompress */
  181.     codecInfoHasEffectParameterList = (1L << 18),                /* codec implements get effects parameter list call, once was codecInfoDoesSkew */
  182.     codecInfoDoesBlend            = (1L << 19),                    /* codec can blend on decompress */
  183.     codecInfoDoesWarp            = (1L << 20),                    /* codec can warp arbitrarily on decompress */
  184.     codecInfoDoesRecompress        = (1L << 21),                    /* codec can recompress image without accumulating errors */
  185.     codecInfoDoesSpool            = (1L << 22),                    /* codec can spool image data */
  186.     codecInfoDoesRateConstrain    = (1L << 23)                    /* codec can data rate constrain */
  187. };
  188.  
  189.  
  190.  
  191. enum {
  192.     codecInfoDepth1                = (1L << 0),                    /* compressed data at 1 bpp depth available */
  193.     codecInfoDepth2                = (1L << 1),                    /* compressed data at 2 bpp depth available */
  194.     codecInfoDepth4                = (1L << 2),                    /* compressed data at 4 bpp depth available */
  195.     codecInfoDepth8                = (1L << 3),                    /* compressed data at 8 bpp depth available */
  196.     codecInfoDepth16            = (1L << 4),                    /* compressed data at 16 bpp depth available */
  197.     codecInfoDepth32            = (1L << 5),                    /* compressed data at 32 bpp depth available */
  198.     codecInfoDepth24            = (1L << 6),                    /* compressed data at 24 bpp depth available */
  199.     codecInfoDepth33            = (1L << 7),                    /* compressed data at 1 bpp monochrome depth  available */
  200.     codecInfoDepth34            = (1L << 8),                    /* compressed data at 2 bpp grayscale depth available */
  201.     codecInfoDepth36            = (1L << 9),                    /* compressed data at 4 bpp grayscale depth available */
  202.     codecInfoDepth40            = (1L << 10),                    /* compressed data at 8 bpp grayscale depth available */
  203.     codecInfoStoresClut            = (1L << 11),                    /* compressed data can have custom cluts */
  204.     codecInfoDoesLossless        = (1L << 12),                    /* compressed data can be stored in lossless format */
  205.     codecInfoSequenceSensitive    = (1L << 13)                    /* compressed data is sensitive to out of sequence decoding */
  206. };
  207.  
  208.  
  209. /* input sequence flags*/
  210.  
  211. enum {
  212.     codecFlagUseImageBuffer        = (1L << 0),                    /* decompress*/
  213.     codecFlagUseScreenBuffer    = (1L << 1),                    /* decompress*/
  214.     codecFlagUpdatePrevious        = (1L << 2),                    /* compress*/
  215.     codecFlagNoScreenUpdate        = (1L << 3),                    /* decompress*/
  216.     codecFlagWasCompressed        = (1L << 4),                    /* compress*/
  217.     codecFlagDontOffscreen        = (1L << 5),                    /* decompress*/
  218.     codecFlagUpdatePreviousComp    = (1L << 6),                    /* compress*/
  219.     codecFlagForceKeyFrame        = (1L << 7),                    /* compress*/
  220.     codecFlagOnlyScreenUpdate    = (1L << 8),                    /* decompress*/
  221.     codecFlagLiveGrab            = (1L << 9),                    /* compress*/
  222.     codecFlagDontUseNewImageBuffer = (1L << 10),                /* decompress*/
  223.     codecFlagInterlaceUpdate    = (1L << 11),                    /* decompress*/
  224.     codecFlagCatchUpDiff        = (1L << 12),                    /* decompress*/
  225.     codecFlagSupportDisable        = (1L << 13),                    /* decompress*/
  226.     codecFlagReenable            = (1L << 14)                    /* decompress*/
  227. };
  228.  
  229. /* output sequence flags*/
  230.  
  231. enum {
  232.     codecFlagOutUpdateOnDataSourceChange = (1L << 10),
  233.     codecFlagSequenceSensitive    = (1L << 11),
  234.     codecFlagOutUpdateOnTimeChange = (1L << 12),
  235.     codecFlagImageBufferNotSourceImage = (1L << 13),
  236.     codecFlagUsedNewImageBuffer    = (1L << 14),
  237.     codecFlagUsedImageBuffer    = (1L << 15)
  238. };
  239.  
  240.  
  241.  
  242.  
  243.  
  244. enum {
  245.                                                                 /* The minimum data size for spooling in or out data */
  246.     codecMinimumDataSize        = 32768L
  247. };
  248.  
  249.  
  250.  
  251.  
  252. enum {
  253.     compressorComponentType        = FOUR_CHAR_CODE('imco'),        /* the type for "Components" which compress images */
  254.     decompressorComponentType    = FOUR_CHAR_CODE('imdc')        /* the type for "Components" which decompress images */
  255. };
  256.  
  257.  
  258. typedef Component                         CompressorComponent;
  259. typedef Component                         DecompressorComponent;
  260. typedef Component                         CodecComponent;
  261. #define    anyCodec                ((CodecComponent)0)
  262. #define    bestSpeedCodec            ((CodecComponent)-1)
  263. #define    bestFidelityCodec        ((CodecComponent)-2)
  264. #define    bestCompressionCodec    ((CodecComponent)-3)
  265. typedef OSType                             CodecType;
  266. typedef unsigned short                     CodecFlags;
  267. typedef unsigned long                     CodecQ;
  268.  
  269. enum {
  270.     codecLosslessQuality        = 0x00000400,
  271.     codecMaxQuality                = 0x000003FF,
  272.     codecMinQuality                = 0x00000000,
  273.     codecLowQuality                = 0x00000100,
  274.     codecNormalQuality            = 0x00000200,
  275.     codecHighQuality            = 0x00000300
  276. };
  277.  
  278.  
  279. enum {
  280.     codecLockBitsShieldCursor    = (1 << 0)                        /* shield cursor */
  281. };
  282.  
  283.  
  284. enum {
  285.     codecCompletionSource        = (1 << 0),                        /* asynchronous codec is done with source data */
  286.     codecCompletionDest            = (1 << 1),                        /* asynchronous codec is done with destination data */
  287.     codecCompletionDontUnshield    = (1 << 2),                        /* on dest complete don't unshield cursor */
  288.     codecCompletionWentOffscreen = (1 << 3),                    /* codec used offscreen buffer */
  289.     codecCompletionUnlockBits    = (1 << 4),                        /* on dest complete, call ICMSequenceUnlockBits */
  290.     codecCompletionForceChainFlush = (1 << 5),                    /* ICM needs to flush the whole chain */
  291.     codecCompletionDropped        = (1 << 6)                        /* codec decided to drop this frame */
  292. };
  293.  
  294.  
  295. enum {
  296.     codecProgressOpen            = 0,
  297.     codecProgressUpdatePercent    = 1,
  298.     codecProgressClose            = 2
  299. };
  300.  
  301. typedef CALLBACK_API( OSErr , ICMDataProcPtr )(Ptr *dataP, long bytesNeeded, long refcon);
  302. typedef CALLBACK_API( OSErr , ICMFlushProcPtr )(Ptr data, long bytesAdded, long refcon);
  303. typedef CALLBACK_API( void , ICMCompletionProcPtr )(OSErr result, short flags, long refcon);
  304. typedef CALLBACK_API( OSErr , ICMProgressProcPtr )(short message, Fixed completeness, long refcon);
  305. typedef CALLBACK_API( void , StdPixProcPtr )(PixMap *src, Rect *srcRect, MatrixRecord *matrix, short mode, RgnHandle mask, PixMap *matte, Rect *matteRect, short flags);
  306. typedef CALLBACK_API( void , QDPixProcPtr )(PixMap *src, Rect *srcRect, MatrixRecord *matrix, short mode, RgnHandle mask, PixMap *matte, Rect *matteRect, short flags);
  307. typedef CALLBACK_API( void , ICMAlignmentProcPtr )(Rect *rp, long refcon);
  308. typedef CALLBACK_API( void , ICMCursorShieldedProcPtr )(const Rect *r, void *refcon, long flags);
  309. typedef CALLBACK_API( void , ICMMemoryDisposedProcPtr )(Ptr memoryBlock, void *refcon);
  310. typedef void *                            ICMCursorNotify;
  311. typedef CALLBACK_API( OSErr , ICMConvertDataFormatProcPtr )(void *refCon, long flags, Handle desiredFormat, Handle sourceDataFormat, void *srcData, long srcDataSize, void **dstData, long *dstDataSize);
  312. typedef STACK_UPP_TYPE(ICMDataProcPtr)                             ICMDataUPP;
  313. typedef STACK_UPP_TYPE(ICMFlushProcPtr)                         ICMFlushUPP;
  314. typedef STACK_UPP_TYPE(ICMCompletionProcPtr)                     ICMCompletionUPP;
  315. typedef STACK_UPP_TYPE(ICMProgressProcPtr)                         ICMProgressUPP;
  316. typedef STACK_UPP_TYPE(StdPixProcPtr)                             StdPixUPP;
  317. typedef STACK_UPP_TYPE(QDPixProcPtr)                             QDPixUPP;
  318. typedef STACK_UPP_TYPE(ICMAlignmentProcPtr)                     ICMAlignmentUPP;
  319. typedef STACK_UPP_TYPE(ICMCursorShieldedProcPtr)                 ICMCursorShieldedUPP;
  320. typedef STACK_UPP_TYPE(ICMMemoryDisposedProcPtr)                 ICMMemoryDisposedUPP;
  321. typedef STACK_UPP_TYPE(ICMConvertDataFormatProcPtr)             ICMConvertDataFormatUPP;
  322. typedef long                             ImageSequence;
  323. typedef long                             ImageSequenceDataSource;
  324. typedef long                             ImageTranscodeSequence;
  325. typedef long                             ImageFieldSequence;
  326.  
  327. struct ICMProgressProcRecord {
  328.     ICMProgressUPP                     progressProc;
  329.     long                             progressRefCon;
  330. };
  331. typedef struct ICMProgressProcRecord    ICMProgressProcRecord;
  332. typedef ICMProgressProcRecord *            ICMProgressProcRecordPtr;
  333.  
  334. struct ICMCompletionProcRecord {
  335.     ICMCompletionUPP                 completionProc;
  336.     long                             completionRefCon;
  337. };
  338. typedef struct ICMCompletionProcRecord    ICMCompletionProcRecord;
  339. typedef ICMCompletionProcRecord *        ICMCompletionProcRecordPtr;
  340.  
  341. struct ICMDataProcRecord {
  342.     ICMDataUPP                         dataProc;
  343.     long                             dataRefCon;
  344. };
  345. typedef struct ICMDataProcRecord        ICMDataProcRecord;
  346. typedef ICMDataProcRecord *                ICMDataProcRecordPtr;
  347.  
  348. struct ICMFlushProcRecord {
  349.     ICMFlushUPP                     flushProc;
  350.     long                             flushRefCon;
  351. };
  352. typedef struct ICMFlushProcRecord        ICMFlushProcRecord;
  353. typedef ICMFlushProcRecord *            ICMFlushProcRecordPtr;
  354.  
  355. struct ICMAlignmentProcRecord {
  356.     ICMAlignmentUPP                 alignmentProc;
  357.     long                             alignmentRefCon;
  358. };
  359. typedef struct ICMAlignmentProcRecord    ICMAlignmentProcRecord;
  360. typedef ICMAlignmentProcRecord *        ICMAlignmentProcRecordPtr;
  361.  
  362. struct DataRateParams {
  363.     long                             dataRate;
  364.     long                             dataOverrun;
  365.     long                             frameDuration;
  366.     long                             keyFrameRate;
  367.     CodecQ                             minSpatialQuality;
  368.     CodecQ                             minTemporalQuality;
  369. };
  370. typedef struct DataRateParams            DataRateParams;
  371. typedef DataRateParams *                DataRateParamsPtr;
  372.  
  373. struct ImageDescription {
  374.     long                             idSize;                        /* total size of ImageDescription including extra data ( CLUTs and other per sequence data ) */
  375.     CodecType                         cType;                        /* what kind of codec compressed this data */
  376.     long                             resvd1;                        /* reserved for Apple use */
  377.     short                             resvd2;                        /* reserved for Apple use */
  378.     short                             dataRefIndex;                /* set to zero  */
  379.     short                             version;                    /* which version is this data */
  380.     short                             revisionLevel;                /* what version of that codec did this */
  381.     long                             vendor;                        /* whose  codec compressed this data */
  382.     CodecQ                             temporalQuality;            /* what was the temporal quality factor  */
  383.     CodecQ                             spatialQuality;                /* what was the spatial quality factor */
  384.     short                             width;                        /* how many pixels wide is this data */
  385.     short                             height;                        /* how many pixels high is this data */
  386.     Fixed                             hRes;                        /* horizontal resolution */
  387.     Fixed                             vRes;                        /* vertical resolution */
  388.     long                             dataSize;                    /* if known, the size of data for this image descriptor */
  389.     short                             frameCount;                    /* number of frames this description applies to */
  390.     Str31                             name;                        /* name of codec ( in case not installed )  */
  391.     short                             depth;                        /* what depth is this data (1-32) or ( 33-40 grayscale ) */
  392.     short                             clutID;                        /* clut id or if 0 clut follows  or -1 if no clut */
  393. };
  394. typedef struct ImageDescription            ImageDescription;
  395. typedef ImageDescription *                ImageDescriptionPtr;
  396. typedef ImageDescriptionPtr *            ImageDescriptionHandle;
  397.  
  398. struct CodecInfo {
  399.     Str31                             typeName;                    /* name of the codec type i.e.: 'Apple Image Compression' */
  400.     short                             version;                    /* version of the codec data that this codec knows about */
  401.     short                             revisionLevel;                /* revision level of this codec i.e: 0x00010001 (1.0.1) */
  402.     long                             vendor;                        /* Maker of this codec i.e: 'appl' */
  403.     long                             decompressFlags;            /* codecInfo flags for decompression capabilities */
  404.     long                             compressFlags;                /* codecInfo flags for compression capabilities */
  405.     long                             formatFlags;                /* codecInfo flags for compression format details */
  406.     UInt8                             compressionAccuracy;        /* measure (1-255) of accuracy of this codec for compress (0 if unknown) */
  407.     UInt8                             decompressionAccuracy;        /* measure (1-255) of accuracy of this codec for decompress (0 if unknown) */
  408.     unsigned short                     compressionSpeed;            /* ( millisecs for compressing 320x240 on base mac II) (0 if unknown)  */
  409.     unsigned short                     decompressionSpeed;            /* ( millisecs for decompressing 320x240 on mac II)(0 if unknown)  */
  410.     UInt8                             compressionLevel;            /* measure (1-255) of compression level of this codec (0 if unknown)  */
  411.     UInt8                             resvd;                        /* pad */
  412.     short                             minimumHeight;                /* minimum height of image (block size) */
  413.     short                             minimumWidth;                /* minimum width of image (block size) */
  414.     short                             decompressPipelineLatency;    /* in milliseconds ( for asynchronous codecs ) */
  415.     short                             compressPipelineLatency;    /* in milliseconds ( for asynchronous codecs ) */
  416.     long                             privateData;
  417. };
  418. typedef struct CodecInfo                CodecInfo;
  419.  
  420. struct CodecNameSpec {
  421.     CodecComponent                     codec;
  422.     CodecType                         cType;
  423.     Str31                             typeName;
  424.     Handle                             name;
  425. };
  426. typedef struct CodecNameSpec            CodecNameSpec;
  427.  
  428. struct CodecNameSpecList {
  429.     short                             count;
  430.     CodecNameSpec                     list[1];
  431. };
  432. typedef struct CodecNameSpecList        CodecNameSpecList;
  433. typedef CodecNameSpecList *                CodecNameSpecListPtr;
  434.  
  435. enum {
  436.     defaultDither                = 0,
  437.     forceDither                    = 1,
  438.     suppressDither                = 2,
  439.     useColorMatching            = 4
  440. };
  441.  
  442.  
  443. enum {
  444.     callStdBits                    = 1,
  445.     callOldBits                    = 2,
  446.     noDefaultOpcodes            = 4
  447. };
  448.  
  449.  
  450. enum {
  451.     graphicsModeStraightAlpha    = 256,
  452.     graphicsModePreWhiteAlpha    = 257,
  453.     graphicsModePreBlackAlpha    = 258,
  454.     graphicsModeComposition        = 259,
  455.     graphicsModeStraightAlphaBlend = 260,
  456.     graphicsModePreMulColorAlpha = 261
  457. };
  458.  
  459.  
  460. enum {
  461.     evenField1ToEvenFieldOut    = 1 << 0,
  462.     evenField1ToOddFieldOut        = 1 << 1,
  463.     oddField1ToEvenFieldOut        = 1 << 2,
  464.     oddField1ToOddFieldOut        = 1 << 3,
  465.     evenField2ToEvenFieldOut    = 1 << 4,
  466.     evenField2ToOddFieldOut        = 1 << 5,
  467.     oddField2ToEvenFieldOut        = 1 << 6,
  468.     oddField2ToOddFieldOut        = 1 << 7
  469. };
  470.  
  471.  
  472. enum {
  473.     icmFrameTimeHasVirtualStartTimeAndDuration = 1 << 0
  474. };
  475.  
  476.  
  477. struct ICMFrameTimeRecord {
  478.     wide                             value;                        /* frame time*/
  479.     long                             scale;                        /* timescale of value/duration fields*/
  480.     void *                            base;                        /* timebase*/
  481.  
  482.     long                             duration;                    /* duration frame is to be displayed (0 if unknown)*/
  483.     Fixed                             rate;                        /* rate of timebase relative to wall-time*/
  484.  
  485.     long                             recordSize;                    /* total number of bytes in ICMFrameTimeRecord*/
  486.  
  487.     long                             frameNumber;                /* number of frame, zero if not known*/
  488.  
  489.     long                             flags;
  490.  
  491.     wide                             virtualStartTime;            /* conceptual start time*/
  492.     long                             virtualDuration;            /* conceptual duration*/
  493. };
  494. typedef struct ICMFrameTimeRecord        ICMFrameTimeRecord;
  495.  
  496. typedef ICMFrameTimeRecord *            ICMFrameTimePtr;
  497. enum { uppICMDataProcInfo = 0x00000FE0 };                         /* pascal 2_bytes Func(4_bytes, 4_bytes, 4_bytes) */
  498. enum { uppICMFlushProcInfo = 0x00000FE0 };                         /* pascal 2_bytes Func(4_bytes, 4_bytes, 4_bytes) */
  499. enum { uppICMCompletionProcInfo = 0x00000E80 };                 /* pascal no_return_value Func(2_bytes, 2_bytes, 4_bytes) */
  500. enum { uppICMProgressProcInfo = 0x00000FA0 };                     /* pascal 2_bytes Func(2_bytes, 4_bytes, 4_bytes) */
  501. enum { uppStdPixProcInfo = 0x002FEFC0 };                         /* pascal no_return_value Func(4_bytes, 4_bytes, 4_bytes, 2_bytes, 4_bytes, 4_bytes, 4_bytes, 2_bytes) */
  502. enum { uppQDPixProcInfo = 0x002FEFC0 };                         /* pascal no_return_value Func(4_bytes, 4_bytes, 4_bytes, 2_bytes, 4_bytes, 4_bytes, 4_bytes, 2_bytes) */
  503. enum { uppICMAlignmentProcInfo = 0x000003C0 };                     /* pascal no_return_value Func(4_bytes, 4_bytes) */
  504. enum { uppICMCursorShieldedProcInfo = 0x00000FC0 };             /* pascal no_return_value Func(4_bytes, 4_bytes, 4_bytes) */
  505. enum { uppICMMemoryDisposedProcInfo = 0x000003C0 };             /* pascal no_return_value Func(4_bytes, 4_bytes) */
  506. enum { uppICMConvertDataFormatProcInfo = 0x003FFFE0 };             /* pascal 2_bytes Func(4_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes, 4_bytes) */
  507. #define NewICMDataProc(userRoutine)                             (ICMDataUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMDataProcInfo, GetCurrentArchitecture())
  508. #define NewICMFlushProc(userRoutine)                             (ICMFlushUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMFlushProcInfo, GetCurrentArchitecture())
  509. #define NewICMCompletionProc(userRoutine)                         (ICMCompletionUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMCompletionProcInfo, GetCurrentArchitecture())
  510. #define NewICMProgressProc(userRoutine)                         (ICMProgressUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMProgressProcInfo, GetCurrentArchitecture())
  511. #define NewStdPixProc(userRoutine)                                 (StdPixUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppStdPixProcInfo, GetCurrentArchitecture())
  512. #define NewQDPixProc(userRoutine)                                 (QDPixUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppQDPixProcInfo, GetCurrentArchitecture())
  513. #define NewICMAlignmentProc(userRoutine)                         (ICMAlignmentUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMAlignmentProcInfo, GetCurrentArchitecture())
  514. #define NewICMCursorShieldedProc(userRoutine)                     (ICMCursorShieldedUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMCursorShieldedProcInfo, GetCurrentArchitecture())
  515. #define NewICMMemoryDisposedProc(userRoutine)                     (ICMMemoryDisposedUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMMemoryDisposedProcInfo, GetCurrentArchitecture())
  516. #define NewICMConvertDataFormatProc(userRoutine)                 (ICMConvertDataFormatUPP)NewRoutineDescriptor((ProcPtr)(userRoutine), uppICMConvertDataFormatProcInfo, GetCurrentArchitecture())
  517. #define CallICMDataProc(userRoutine, dataP, bytesNeeded, refcon)  CALL_THREE_PARAMETER_UPP((userRoutine), uppICMDataProcInfo, (dataP), (bytesNeeded), (refcon))
  518. #define CallICMFlushProc(userRoutine, data, bytesAdded, refcon)  CALL_THREE_PARAMETER_UPP((userRoutine), uppICMFlushProcInfo, (data), (bytesAdded), (refcon))
  519. #define CallICMCompletionProc(userRoutine, result, flags, refcon)  CALL_THREE_PARAMETER_UPP((userRoutine), uppICMCompletionProcInfo, (result), (flags), (refcon))
  520. #define CallICMProgressProc(userRoutine, message, completeness, refcon)  CALL_THREE_PARAMETER_UPP((userRoutine), uppICMProgressProcInfo, (message), (completeness), (refcon))
  521. #define CallStdPixProc(userRoutine, src, srcRect, matrix, mode, mask, matte, matteRect, flags)  CALL_EIGHT_PARAMETER_UPP((userRoutine), uppStdPixProcInfo, (src), (srcRect), (matrix), (mode), (mask), (matte), (matteRect), (flags))
  522. #define CallQDPixProc(userRoutine, src, srcRect, matrix, mode, mask, matte, matteRect, flags)  CALL_EIGHT_PARAMETER_UPP((userRoutine), uppQDPixProcInfo, (src), (srcRect), (matrix), (mode), (mask), (matte), (matteRect), (flags))
  523. #define CallICMAlignmentProc(userRoutine, rp, refcon)             CALL_TWO_PARAMETER_UPP((userRoutine), uppICMAlignmentProcInfo, (rp), (refcon))
  524. #define CallICMCursorShieldedProc(userRoutine, r, refcon, flags)  CALL_THREE_PARAMETER_UPP((userRoutine), uppICMCursorShieldedProcInfo, (r), (refcon), (flags))
  525. #define CallICMMemoryDisposedProc(userRoutine, memoryBlock, refcon)  CALL_TWO_PARAMETER_UPP((userRoutine), uppICMMemoryDisposedProcInfo, (memoryBlock), (refcon))
  526. #define CallICMConvertDataFormatProc(userRoutine, refCon, flags, desiredFormat, sourceDataFormat, srcData, srcDataSize, dstData, dstDataSize)  CALL_EIGHT_PARAMETER_UPP((userRoutine), uppICMConvertDataFormatProcInfo, (refCon), (flags), (desiredFormat), (sourceDataFormat), (srcData), (srcDataSize), (dstData), (dstDataSize))
  527.  
  528. EXTERN_API( OSErr )
  529. CodecManagerVersion                (long *                    version)                            TWOWORDINLINE(0x7000, 0xAAA3);
  530.  
  531. EXTERN_API( OSErr )
  532. GetCodecNameList                (CodecNameSpecListPtr *    list,
  533.                                  short                     showAll)                            TWOWORDINLINE(0x7001, 0xAAA3);
  534.  
  535. EXTERN_API( OSErr )
  536. DisposeCodecNameList            (CodecNameSpecListPtr     list)                                TWOWORDINLINE(0x700F, 0xAAA3);
  537.  
  538. EXTERN_API( OSErr )
  539. GetCodecInfo                    (CodecInfo *            info,
  540.                                  CodecType                 cType,
  541.                                  CodecComponent         codec)                                TWOWORDINLINE(0x7003, 0xAAA3);
  542.  
  543. EXTERN_API( OSErr )
  544. GetMaxCompressionSize            (PixMapHandle             src,
  545.                                  const Rect *            srcRect,
  546.                                  short                     colorDepth,
  547.                                  CodecQ                 quality,
  548.                                  CodecType                 cType,
  549.                                  CompressorComponent     codec,
  550.                                  long *                    size)                                TWOWORDINLINE(0x7004, 0xAAA3);
  551.  
  552. EXTERN_API( OSErr )
  553. GetCSequenceMaxCompressionSize    (ImageSequence             seqID,
  554.                                  PixMapHandle             src,
  555.                                  long *                    size)                                FOURWORDINLINE(0x203C, 0x000C, 0x0074, 0xAAA3);
  556.  
  557. EXTERN_API( OSErr )
  558. GetCompressionTime                (PixMapHandle             src,
  559.                                  const Rect *            srcRect,
  560.                                  short                     colorDepth,
  561.                                  CodecType                 cType,
  562.                                  CompressorComponent     codec,
  563.                                  CodecQ *                spatialQuality,
  564.                                  CodecQ *                temporalQuality,
  565.                                  unsigned long *        compressTime)                        TWOWORDINLINE(0x7005, 0xAAA3);
  566.  
  567. EXTERN_API( OSErr )
  568. CompressImage                    (PixMapHandle             src,
  569.                                  const Rect *            srcRect,
  570.                                  CodecQ                 quality,
  571.                                  CodecType                 cType,
  572.                                  ImageDescriptionHandle  desc,
  573.                                  Ptr                     data)                                TWOWORDINLINE(0x7006, 0xAAA3);
  574.  
  575. EXTERN_API( OSErr )
  576. FCompressImage                    (PixMapHandle             src,
  577.                                  const Rect *            srcRect,
  578.                                  short                     colorDepth,
  579.                                  CodecQ                 quality,
  580.                                  CodecType                 cType,
  581.                                  CompressorComponent     codec,
  582.                                  CTabHandle             ctable,
  583.                                  CodecFlags             flags,
  584.                                  long                     bufferSize,
  585.                                  ICMFlushProcRecordPtr     flushProc,
  586.                                  ICMProgressProcRecordPtr  progressProc,
  587.                                  ImageDescriptionHandle  desc,
  588.                                  Ptr                     data)                                TWOWORDINLINE(0x7007, 0xAAA3);
  589.  
  590. EXTERN_API( OSErr )
  591. DecompressImage                    (Ptr                     data,
  592.                                  ImageDescriptionHandle  desc,
  593.                                  PixMapHandle             dst,
  594.                                  const Rect *            srcRect,
  595.                                  const Rect *            dstRect,
  596.                                  short                     mode,
  597.                                  RgnHandle                 mask)                                TWOWORDINLINE(0x7008, 0xAAA3);
  598.  
  599. EXTERN_API( OSErr )
  600. FDecompressImage                (Ptr                     data,
  601.                                  ImageDescriptionHandle  desc,
  602.                                  PixMapHandle             dst,
  603.                                  const Rect *            srcRect,
  604.                                  MatrixRecordPtr         matrix,
  605.                                  short                     mode,
  606.                                  RgnHandle                 mask,
  607.                                  PixMapHandle             matte,
  608.                                  const Rect *            matteRect,
  609.                                  CodecQ                 accuracy,
  610.                                  DecompressorComponent     codec,
  611.                                  long                     bufferSize,
  612.                                  ICMDataProcRecordPtr     dataProc,
  613.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x7009, 0xAAA3);
  614.  
  615. EXTERN_API( OSErr )
  616. CompressSequenceBegin            (ImageSequence *        seqID,
  617.                                  PixMapHandle             src,
  618.                                  PixMapHandle             prev,
  619.                                  const Rect *            srcRect,
  620.                                  const Rect *            prevRect,
  621.                                  short                     colorDepth,
  622.                                  CodecType                 cType,
  623.                                  CompressorComponent     codec,
  624.                                  CodecQ                 spatialQuality,
  625.                                  CodecQ                 temporalQuality,
  626.                                  long                     keyFrameRate,
  627.                                  CTabHandle             ctable,
  628.                                  CodecFlags             flags,
  629.                                  ImageDescriptionHandle  desc)                                TWOWORDINLINE(0x700A, 0xAAA3);
  630.  
  631. EXTERN_API( OSErr )
  632. CompressSequenceFrame            (ImageSequence             seqID,
  633.                                  PixMapHandle             src,
  634.                                  const Rect *            srcRect,
  635.                                  CodecFlags             flags,
  636.                                  Ptr                     data,
  637.                                  long *                    dataSize,
  638.                                  UInt8 *                similarity,
  639.                                  ICMCompletionProcRecordPtr  asyncCompletionProc)            TWOWORDINLINE(0x700B, 0xAAA3);
  640.  
  641. EXTERN_API( OSErr )
  642. DecompressSequenceBegin            (ImageSequence *        seqID,
  643.                                  ImageDescriptionHandle  desc,
  644.                                  CGrafPtr                 port,
  645.                                  GDHandle                 gdh,
  646.                                  const Rect *            srcRect,
  647.                                  MatrixRecordPtr         matrix,
  648.                                  short                     mode,
  649.                                  RgnHandle                 mask,
  650.                                  CodecFlags             flags,
  651.                                  CodecQ                 accuracy,
  652.                                  DecompressorComponent     codec)                                TWOWORDINLINE(0x700D, 0xAAA3);
  653.  
  654. EXTERN_API( OSErr )
  655. DecompressSequenceBeginS        (ImageSequence *        seqID,
  656.                                  ImageDescriptionHandle  desc,
  657.                                  Ptr                     data,
  658.                                  long                     dataSize,
  659.                                  CGrafPtr                 port,
  660.                                  GDHandle                 gdh,
  661.                                  const Rect *            srcRect,
  662.                                  MatrixRecordPtr         matrix,
  663.                                  short                     mode,
  664.                                  RgnHandle                 mask,
  665.                                  CodecFlags             flags,
  666.                                  CodecQ                 accuracy,
  667.                                  DecompressorComponent     codec)                                FOURWORDINLINE(0x203C, 0x0030, 0x005D, 0xAAA3);
  668.  
  669. EXTERN_API( OSErr )
  670. DecompressSequenceFrame            (ImageSequence             seqID,
  671.                                  Ptr                     data,
  672.                                  CodecFlags             inFlags,
  673.                                  CodecFlags *            outFlags,
  674.                                  ICMCompletionProcRecordPtr  asyncCompletionProc)            TWOWORDINLINE(0x700E, 0xAAA3);
  675.  
  676. EXTERN_API( OSErr )
  677. DecompressSequenceFrameS        (ImageSequence             seqID,
  678.                                  Ptr                     data,
  679.                                  long                     dataSize,
  680.                                  CodecFlags             inFlags,
  681.                                  CodecFlags *            outFlags,
  682.                                  ICMCompletionProcRecordPtr  asyncCompletionProc)            FOURWORDINLINE(0x203C, 0x0016, 0x0047, 0xAAA3);
  683.  
  684. EXTERN_API( OSErr )
  685. DecompressSequenceFrameWhen        (ImageSequence             seqID,
  686.                                  Ptr                     data,
  687.                                  long                     dataSize,
  688.                                  CodecFlags             inFlags,
  689.                                  CodecFlags *            outFlags,
  690.                                  ICMCompletionProcRecordPtr  asyncCompletionProc,
  691.                                  const ICMFrameTimeRecord * frameTime)                        FOURWORDINLINE(0x203C, 0x001A, 0x005E, 0xAAA3);
  692.  
  693. EXTERN_API( OSErr )
  694. CDSequenceFlush                    (ImageSequence             seqID)                                FOURWORDINLINE(0x203C, 0x0004, 0x005F, 0xAAA3);
  695.  
  696. EXTERN_API( OSErr )
  697. SetDSequenceMatrix                (ImageSequence             seqID,
  698.                                  MatrixRecordPtr         matrix)                                TWOWORDINLINE(0x7010, 0xAAA3);
  699.  
  700. EXTERN_API( OSErr )
  701. SetDSequenceMatte                (ImageSequence             seqID,
  702.                                  PixMapHandle             matte,
  703.                                  const Rect *            matteRect)                            TWOWORDINLINE(0x7011, 0xAAA3);
  704.  
  705. EXTERN_API( OSErr )
  706. SetDSequenceMask                (ImageSequence             seqID,
  707.                                  RgnHandle                 mask)                                TWOWORDINLINE(0x7012, 0xAAA3);
  708.  
  709. EXTERN_API( OSErr )
  710. SetDSequenceTransferMode        (ImageSequence             seqID,
  711.                                  short                     mode,
  712.                                  const RGBColor *        opColor)                            TWOWORDINLINE(0x7013, 0xAAA3);
  713.  
  714. EXTERN_API( OSErr )
  715. SetDSequenceDataProc            (ImageSequence             seqID,
  716.                                  ICMDataProcRecordPtr     dataProc,
  717.                                  long                     bufferSize)                            TWOWORDINLINE(0x7014, 0xAAA3);
  718.  
  719. EXTERN_API( OSErr )
  720. SetDSequenceAccuracy            (ImageSequence             seqID,
  721.                                  CodecQ                 accuracy)                            TWOWORDINLINE(0x7034, 0xAAA3);
  722.  
  723. EXTERN_API( OSErr )
  724. SetDSequenceSrcRect                (ImageSequence             seqID,
  725.                                  const Rect *            srcRect)                            TWOWORDINLINE(0x7035, 0xAAA3);
  726.  
  727.  
  728. EXTERN_API( OSErr )
  729. GetDSequenceImageBuffer            (ImageSequence             seqID,
  730.                                  GWorldPtr *            gworld)                                TWOWORDINLINE(0x7015, 0xAAA3);
  731.  
  732. EXTERN_API( OSErr )
  733. GetDSequenceScreenBuffer        (ImageSequence             seqID,
  734.                                  GWorldPtr *            gworld)                                TWOWORDINLINE(0x7016, 0xAAA3);
  735.  
  736. EXTERN_API( OSErr )
  737. SetCSequenceQuality                (ImageSequence             seqID,
  738.                                  CodecQ                 spatialQuality,
  739.                                  CodecQ                 temporalQuality)                    TWOWORDINLINE(0x7017, 0xAAA3);
  740.  
  741. EXTERN_API( OSErr )
  742. SetCSequencePrev                (ImageSequence             seqID,
  743.                                  PixMapHandle             prev,
  744.                                  const Rect *            prevRect)                            TWOWORDINLINE(0x7018, 0xAAA3);
  745.  
  746. EXTERN_API( OSErr )
  747. SetCSequenceFlushProc            (ImageSequence             seqID,
  748.                                  ICMFlushProcRecordPtr     flushProc,
  749.                                  long                     bufferSize)                            TWOWORDINLINE(0x7033, 0xAAA3);
  750.  
  751. EXTERN_API( OSErr )
  752. SetCSequenceKeyFrameRate        (ImageSequence             seqID,
  753.                                  long                     keyFrameRate)                        TWOWORDINLINE(0x7036, 0xAAA3);
  754.  
  755. EXTERN_API( OSErr )
  756. GetCSequenceKeyFrameRate        (ImageSequence             seqID,
  757.                                  long *                    keyFrameRate)                        FOURWORDINLINE(0x203C, 0x0008, 0x004B, 0xAAA3);
  758.  
  759. EXTERN_API( OSErr )
  760. GetCSequencePrevBuffer            (ImageSequence             seqID,
  761.                                  GWorldPtr *            gworld)                                TWOWORDINLINE(0x7019, 0xAAA3);
  762.  
  763. EXTERN_API( OSErr )
  764. CDSequenceBusy                    (ImageSequence             seqID)                                TWOWORDINLINE(0x701A, 0xAAA3);
  765.  
  766. EXTERN_API( OSErr )
  767. CDSequenceEnd                    (ImageSequence             seqID)                                TWOWORDINLINE(0x701B, 0xAAA3);
  768.  
  769. EXTERN_API( OSErr )
  770. CDSequenceEquivalentImageDescription (ImageSequence     seqID,
  771.                                  ImageDescriptionHandle  newDesc,
  772.                                  Boolean *                equivalent)                            FOURWORDINLINE(0x203C, 0x000C, 0x0065, 0xAAA3);
  773.  
  774. EXTERN_API( OSErr )
  775. GetCompressedImageSize            (ImageDescriptionHandle  desc,
  776.                                  Ptr                     data,
  777.                                  long                     bufferSize,
  778.                                  ICMDataProcRecordPtr     dataProc,
  779.                                  long *                    dataSize)                            TWOWORDINLINE(0x701C, 0xAAA3);
  780.  
  781. EXTERN_API( OSErr )
  782. GetSimilarity                    (PixMapHandle             src,
  783.                                  const Rect *            srcRect,
  784.                                  ImageDescriptionHandle  desc,
  785.                                  Ptr                     data,
  786.                                  Fixed *                similarity)                            TWOWORDINLINE(0x701D, 0xAAA3);
  787.  
  788.  
  789. enum {
  790.     kImageDescriptionSampleFormat = FOUR_CHAR_CODE('idfm'),        /* image description extension describing sample format*/
  791.     kImageDescriptionClassicAtomFormat = FOUR_CHAR_CODE('atom'), /* sample contains classic atom structure (ie, GX codec and Curve codec)*/
  792.     kImageDescriptionQTAtomFormat = FOUR_CHAR_CODE('qtat'),        /* sample contains QT atom structure*/
  793.     kImageDescriptionEffectDataFormat = FOUR_CHAR_CODE('fxat'),    /* sample describes an effect (as QTAtoms)*/
  794.     kImageDescriptionPrivateDataFormat = FOUR_CHAR_CODE('priv'), /* sample is in a private codec specific format*/
  795.     kImageDescriptionAlternateCodec = FOUR_CHAR_CODE('subs')    /* image description extension containing the OSType of a substitute codec should the main codec not be available*/
  796. };
  797.  
  798. EXTERN_API( OSErr )
  799. GetImageDescriptionCTable        (ImageDescriptionHandle  desc,
  800.                                  CTabHandle *            ctable)                                TWOWORDINLINE(0x701E, 0xAAA3);
  801.  
  802. EXTERN_API( OSErr )
  803. SetImageDescriptionCTable        (ImageDescriptionHandle  desc,
  804.                                  CTabHandle             ctable)                                TWOWORDINLINE(0x701F, 0xAAA3);
  805.  
  806. EXTERN_API( OSErr )
  807. GetImageDescriptionExtension    (ImageDescriptionHandle  desc,
  808.                                  Handle *                extension,
  809.                                  long                     idType,
  810.                                  long                     index)                                TWOWORDINLINE(0x7020, 0xAAA3);
  811.  
  812. EXTERN_API( OSErr )
  813. AddImageDescriptionExtension    (ImageDescriptionHandle  desc,
  814.                                  Handle                 extension,
  815.                                  long                     idType)                                TWOWORDINLINE(0x7021, 0xAAA3);
  816.  
  817. EXTERN_API( OSErr )
  818. RemoveImageDescriptionExtension    (ImageDescriptionHandle  desc,
  819.                                  long                     idType,
  820.                                  long                     index)                                FOURWORDINLINE(0x203C, 0x000C, 0x003A, 0xAAA3);
  821.  
  822. EXTERN_API( OSErr )
  823. CountImageDescriptionExtensionType (ImageDescriptionHandle  desc,
  824.                                  long                     idType,
  825.                                  long *                    count)                                FOURWORDINLINE(0x203C, 0x000C, 0x003B, 0xAAA3);
  826.  
  827. EXTERN_API( OSErr )
  828. GetNextImageDescriptionExtensionType (ImageDescriptionHandle  desc,
  829.                                  long *                    idType)                                FOURWORDINLINE(0x203C, 0x0008, 0x003C, 0xAAA3);
  830.  
  831. EXTERN_API( OSErr )
  832. FindCodec                        (CodecType                 cType,
  833.                                  CodecComponent         specCodec,
  834.                                  CompressorComponent *    compressor,
  835.                                  DecompressorComponent * decompressor)                        TWOWORDINLINE(0x7023, 0xAAA3);
  836.  
  837. EXTERN_API( OSErr )
  838. CompressPicture                    (PicHandle                 srcPicture,
  839.                                  PicHandle                 dstPicture,
  840.                                  CodecQ                 quality,
  841.                                  CodecType                 cType)                                TWOWORDINLINE(0x7024, 0xAAA3);
  842.  
  843. EXTERN_API( OSErr )
  844. FCompressPicture                (PicHandle                 srcPicture,
  845.                                  PicHandle                 dstPicture,
  846.                                  short                     colorDepth,
  847.                                  CTabHandle             ctable,
  848.                                  CodecQ                 quality,
  849.                                  short                     doDither,
  850.                                  short                     compressAgain,
  851.                                  ICMProgressProcRecordPtr  progressProc,
  852.                                  CodecType                 cType,
  853.                                  CompressorComponent     codec)                                TWOWORDINLINE(0x7025, 0xAAA3);
  854.  
  855. EXTERN_API( OSErr )
  856. CompressPictureFile                (short                     srcRefNum,
  857.                                  short                     dstRefNum,
  858.                                  CodecQ                 quality,
  859.                                  CodecType                 cType)                                TWOWORDINLINE(0x7026, 0xAAA3);
  860.  
  861. EXTERN_API( OSErr )
  862. FCompressPictureFile            (short                     srcRefNum,
  863.                                  short                     dstRefNum,
  864.                                  short                     colorDepth,
  865.                                  CTabHandle             ctable,
  866.                                  CodecQ                 quality,
  867.                                  short                     doDither,
  868.                                  short                     compressAgain,
  869.                                  ICMProgressProcRecordPtr  progressProc,
  870.                                  CodecType                 cType,
  871.                                  CompressorComponent     codec)                                TWOWORDINLINE(0x7027, 0xAAA3);
  872.  
  873. EXTERN_API( OSErr )
  874. GetPictureFileHeader            (short                     refNum,
  875.                                  Rect *                    frame,
  876.                                  OpenCPicParams *        header)                                TWOWORDINLINE(0x7028, 0xAAA3);
  877.  
  878. EXTERN_API( OSErr )
  879. DrawPictureFile                    (short                     refNum,
  880.                                  const Rect *            frame,
  881.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x7029, 0xAAA3);
  882.  
  883. EXTERN_API( OSErr )
  884. DrawTrimmedPicture                (PicHandle                 srcPicture,
  885.                                  const Rect *            frame,
  886.                                  RgnHandle                 trimMask,
  887.                                  short                     doDither,
  888.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702E, 0xAAA3);
  889.  
  890. EXTERN_API( OSErr )
  891. DrawTrimmedPictureFile            (short                     srcRefnum,
  892.                                  const Rect *            frame,
  893.                                  RgnHandle                 trimMask,
  894.                                  short                     doDither,
  895.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702F, 0xAAA3);
  896.  
  897. EXTERN_API( OSErr )
  898. MakeThumbnailFromPicture        (PicHandle                 picture,
  899.                                  short                     colorDepth,
  900.                                  PicHandle                 thumbnail,
  901.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702A, 0xAAA3);
  902.  
  903. EXTERN_API( OSErr )
  904. MakeThumbnailFromPictureFile    (short                     refNum,
  905.                                  short                     colorDepth,
  906.                                  PicHandle                 thumbnail,
  907.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702B, 0xAAA3);
  908.  
  909. EXTERN_API( OSErr )
  910. MakeThumbnailFromPixMap            (PixMapHandle             src,
  911.                                  const Rect *            srcRect,
  912.                                  short                     colorDepth,
  913.                                  PicHandle                 thumbnail,
  914.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702C, 0xAAA3);
  915.  
  916. EXTERN_API( OSErr )
  917. TrimImage                        (ImageDescriptionHandle  desc,
  918.                                  Ptr                     inData,
  919.                                  long                     inBufferSize,
  920.                                  ICMDataProcRecordPtr     dataProc,
  921.                                  Ptr                     outData,
  922.                                  long                     outBufferSize,
  923.                                  ICMFlushProcRecordPtr     flushProc,
  924.                                  Rect *                    trimRect,
  925.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x702D, 0xAAA3);
  926.  
  927. EXTERN_API( OSErr )
  928. ConvertImage                    (ImageDescriptionHandle  srcDD,
  929.                                  Ptr                     srcData,
  930.                                  short                     colorDepth,
  931.                                  CTabHandle             ctable,
  932.                                  CodecQ                 accuracy,
  933.                                  CodecQ                 quality,
  934.                                  CodecType                 cType,
  935.                                  CodecComponent         codec,
  936.                                  ImageDescriptionHandle  dstDD,
  937.                                  Ptr                     dstData)                            TWOWORDINLINE(0x7030, 0xAAA3);
  938.  
  939. EXTERN_API( OSErr )
  940. GetCompressedPixMapInfo            (PixMapPtr                 pix,
  941.                                  ImageDescriptionHandle * desc,
  942.                                  Ptr *                    data,
  943.                                  long *                    bufferSize,
  944.                                  ICMDataProcRecord *    dataProc,
  945.                                  ICMProgressProcRecord * progressProc)                        TWOWORDINLINE(0x7037, 0xAAA3);
  946.  
  947. EXTERN_API( OSErr )
  948. SetCompressedPixMapInfo            (PixMapPtr                 pix,
  949.                                  ImageDescriptionHandle  desc,
  950.                                  Ptr                     data,
  951.                                  long                     bufferSize,
  952.                                  ICMDataProcRecordPtr     dataProc,
  953.                                  ICMProgressProcRecordPtr  progressProc)                    TWOWORDINLINE(0x7038, 0xAAA3);
  954.  
  955. EXTERN_API( void )
  956. StdPix                            (PixMapPtr                 src,
  957.                                  const Rect *            srcRect,
  958.                                  MatrixRecordPtr         matrix,
  959.                                  short                     mode,
  960.                                  RgnHandle                 mask,
  961.                                  PixMapPtr                 matte,
  962.                                  const Rect *            matteRect,
  963.                                  short                     flags)                                TWOWORDINLINE(0x700C, 0xAAA3);
  964.  
  965. EXTERN_API( OSErr )
  966. TransformRgn                    (MatrixRecordPtr         matrix,
  967.                                  RgnHandle                 rgn)                                TWOWORDINLINE(0x7039, 0xAAA3);
  968.  
  969.  
  970. /***********
  971.     preview stuff
  972. ***********/
  973. EXTERN_API( void )
  974. SFGetFilePreview                (Point                     where,
  975.                                  ConstStr255Param         prompt,
  976.                                  FileFilterUPP             fileFilter,
  977.                                  short                     numTypes,
  978.                                  ConstSFTypeListPtr     typeList,
  979.                                  DlgHookUPP             dlgHook,
  980.                                  SFReply *                reply)                                TWOWORDINLINE(0x7041, 0xAAA3);
  981.  
  982. EXTERN_API( void )
  983. SFPGetFilePreview                (Point                     where,
  984.                                  ConstStr255Param         prompt,
  985.                                  FileFilterUPP             fileFilter,
  986.                                  short                     numTypes,
  987.                                  ConstSFTypeListPtr     typeList,
  988.                                  DlgHookUPP             dlgHook,
  989.                                  SFReply *                reply,
  990.                                  short                     dlgID,
  991.                                  ModalFilterUPP         filterProc)                            TWOWORDINLINE(0x7042, 0xAAA3);
  992.  
  993. EXTERN_API( void )
  994. StandardGetFilePreview            (FileFilterUPP             fileFilter,
  995.                                  short                     numTypes,
  996.                                  ConstSFTypeListPtr     typeList,
  997.                                  StandardFileReply *    reply)                                TWOWORDINLINE(0x7043, 0xAAA3);
  998.  
  999. EXTERN_API( void )
  1000. CustomGetFilePreview            (FileFilterYDUPP         fileFilter,
  1001.                                  short                     numTypes,
  1002.                                  ConstSFTypeListPtr     typeList,
  1003.                                  StandardFileReply *    reply,
  1004.                                  short                     dlgID,
  1005.                                  Point                     where,
  1006.                                  DlgHookYDUPP             dlgHook,
  1007.                                  ModalFilterYDUPP         filterProc,
  1008.                                  ActivationOrderListPtr  activeList,
  1009.                                  ActivateYDUPP             activateProc,
  1010.                                  void *                    yourDataPtr)                        TWOWORDINLINE(0x7044, 0xAAA3);
  1011.  
  1012. EXTERN_API( OSErr )
  1013. MakeFilePreview                    (short                     resRefNum,
  1014.                                  ICMProgressProcRecordPtr  progress)                        TWOWORDINLINE(0x7045, 0xAAA3);
  1015.  
  1016. EXTERN_API( OSErr )
  1017. AddFilePreview                    (short                     resRefNum,
  1018.                                  OSType                 previewType,
  1019.                                  Handle                 previewData)                        TWOWORDINLINE(0x7046, 0xAAA3);
  1020.  
  1021.  
  1022. enum {
  1023.     sfpItemPreviewAreaUser        = 11,
  1024.     sfpItemPreviewStaticText    = 12,
  1025.     sfpItemPreviewDividerUser    = 13,
  1026.     sfpItemCreatePreviewButton    = 14,
  1027.     sfpItemShowPreviewButton    = 15
  1028. };
  1029.  
  1030.  
  1031. struct PreviewResourceRecord {
  1032.     unsigned long                     modDate;
  1033.     short                             version;
  1034.     OSType                             resType;
  1035.     short                             resID;
  1036. };
  1037. typedef struct PreviewResourceRecord    PreviewResourceRecord;
  1038.  
  1039. typedef PreviewResourceRecord *            PreviewResourcePtr;
  1040. typedef PreviewResourcePtr *            PreviewResource;
  1041. EXTERN_API( void )
  1042. AlignScreenRect                    (Rect *                    rp,
  1043.                                  ICMAlignmentProcRecordPtr  alignmentProc)                    FOURWORDINLINE(0x203C, 0x0008, 0x004C, 0xAAA3);
  1044.  
  1045. EXTERN_API( void )
  1046. AlignWindow                        (WindowPtr                 wp,
  1047.                                  Boolean                 front,
  1048.                                  const Rect *            alignmentRect,
  1049.                                  ICMAlignmentProcRecordPtr  alignmentProc)                    FOURWORDINLINE(0x203C, 0x000E, 0x004D, 0xAAA3);
  1050.  
  1051. EXTERN_API( void )
  1052. DragAlignedWindow                (WindowPtr                 wp,
  1053.                                  Point                     startPt,
  1054.                                  Rect *                    boundsRect,
  1055.                                  Rect *                    alignmentRect,
  1056.                                  ICMAlignmentProcRecordPtr  alignmentProc)                    FOURWORDINLINE(0x203C, 0x0014, 0x004E, 0xAAA3);
  1057.  
  1058. EXTERN_API( long )
  1059. DragAlignedGrayRgn                (RgnHandle                 theRgn,
  1060.                                  Point                     startPt,
  1061.                                  Rect *                    boundsRect,
  1062.                                  Rect *                    slopRect,
  1063.                                  short                     axis,
  1064.                                  UniversalProcPtr         actionProc,
  1065.                                  Rect *                    alignmentRect,
  1066.                                  ICMAlignmentProcRecordPtr  alignmentProc)                    FOURWORDINLINE(0x203C, 0x001E, 0x004F, 0xAAA3);
  1067.  
  1068. EXTERN_API( OSErr )
  1069. SetCSequenceDataRateParams        (ImageSequence             seqID,
  1070.                                  DataRateParamsPtr         params)                                FOURWORDINLINE(0x203C, 0x0008, 0x0050, 0xAAA3);
  1071.  
  1072. EXTERN_API( OSErr )
  1073. SetCSequenceFrameNumber            (ImageSequence             seqID,
  1074.                                  long                     frameNumber)                        FOURWORDINLINE(0x203C, 0x0008, 0x0051, 0xAAA3);
  1075.  
  1076. EXTERN_API( OSErr )
  1077. SetCSequencePreferredPacketSize    (ImageSequence             seqID,
  1078.                                  long                     preferredPacketSizeInBytes)            FOURWORDINLINE(0x203C, 0x0008, 0x0078, 0xAAA3);
  1079.  
  1080. EXTERN_API( OSErr )
  1081. NewImageGWorld                    (GWorldPtr *            gworld,
  1082.                                  ImageDescriptionHandle  idh,
  1083.                                  GWorldFlags             flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x0052, 0xAAA3);
  1084.  
  1085. EXTERN_API( OSErr )
  1086. GetCSequenceDataRateParams        (ImageSequence             seqID,
  1087.                                  DataRateParamsPtr         params)                                FOURWORDINLINE(0x203C, 0x0008, 0x0053, 0xAAA3);
  1088.  
  1089. EXTERN_API( OSErr )
  1090. GetCSequenceFrameNumber            (ImageSequence             seqID,
  1091.                                  long *                    frameNumber)                        FOURWORDINLINE(0x203C, 0x0008, 0x0054, 0xAAA3);
  1092.  
  1093. EXTERN_API( OSErr )
  1094. GetBestDeviceRect                (GDHandle *                gdh,
  1095.                                  Rect *                    rp)                                    FOURWORDINLINE(0x203C, 0x0008, 0x0055, 0xAAA3);
  1096.  
  1097. EXTERN_API( OSErr )
  1098. SetSequenceProgressProc            (ImageSequence             seqID,
  1099.                                  ICMProgressProcRecord * progressProc)                        FOURWORDINLINE(0x203C, 0x0008, 0x0056, 0xAAA3);
  1100.  
  1101. EXTERN_API( OSErr )
  1102. GDHasScale                        (GDHandle                 gdh,
  1103.                                  short                     depth,
  1104.                                  Fixed *                scale)                                FOURWORDINLINE(0x203C, 0x000A, 0x005A, 0xAAA3);
  1105.  
  1106. EXTERN_API( OSErr )
  1107. GDGetScale                        (GDHandle                 gdh,
  1108.                                  Fixed *                scale,
  1109.                                  short *                flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x005B, 0xAAA3);
  1110.  
  1111. EXTERN_API( OSErr )
  1112. GDSetScale                        (GDHandle                 gdh,
  1113.                                  Fixed                     scale,
  1114.                                  short                     flags)                                FOURWORDINLINE(0x203C, 0x000A, 0x005C, 0xAAA3);
  1115.  
  1116. EXTERN_API( OSErr )
  1117. ICMShieldSequenceCursor            (ImageSequence             seqID)                                FOURWORDINLINE(0x203C, 0x0004, 0x0062, 0xAAA3);
  1118.  
  1119. EXTERN_API( void )
  1120. ICMDecompressComplete            (ImageSequence             seqID,
  1121.                                  OSErr                     err,
  1122.                                  short                     flag,
  1123.                                  ICMCompletionProcRecordPtr  completionRtn)                    FOURWORDINLINE(0x203C, 0x000C, 0x0063, 0xAAA3);
  1124.  
  1125. EXTERN_API( OSErr )
  1126. ICMDecompressCompleteS            (ImageSequence             seqID,
  1127.                                  OSErr                     err,
  1128.                                  short                     flag,
  1129.                                  ICMCompletionProcRecordPtr  completionRtn)                    FOURWORDINLINE(0x203C, 0x000C, 0x0082, 0xAAA3);
  1130.  
  1131. EXTERN_API( OSErr )
  1132. ICMSequenceLockBits                (ImageSequence             seqID,
  1133.                                  PixMapPtr                 dst,
  1134.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x007C, 0xAAA3);
  1135.  
  1136. EXTERN_API( OSErr )
  1137. ICMSequenceUnlockBits            (ImageSequence             seqID,
  1138.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x0008, 0x007D, 0xAAA3);
  1139.  
  1140.  
  1141. struct ICMPixelFormatInfo {
  1142.     long                             size;
  1143.     unsigned long                     formatFlags;
  1144.     short                             pixelSize;
  1145.     short                             reserved0;
  1146.     long                             reserved2;
  1147. };
  1148. typedef struct ICMPixelFormatInfo        ICMPixelFormatInfo;
  1149. typedef ICMPixelFormatInfo *            ICMPixelFormatInfoPtr;
  1150. EXTERN_API( OSErr )
  1151. ICMGetPixelFormatInfo            (OSType                 PixelFormat,
  1152.                                  ICMPixelFormatInfoPtr     theInfo)                            FOURWORDINLINE(0x203C, 0x0008, 0x0083, 0xAAA3);
  1153.  
  1154.  
  1155. enum {
  1156.     kICMGetChainUltimateParent    = 0,
  1157.     kICMGetChainParent            = 1,
  1158.     kICMGetChainChild            = 2,
  1159.     kICMGetChainUltimateChild    = 3
  1160. };
  1161.  
  1162. EXTERN_API( OSErr )
  1163. ICMSequenceGetChainMember        (ImageSequence             seqID,
  1164.                                  ImageSequence *        retSeqID,
  1165.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x007E, 0xAAA3);
  1166.  
  1167. EXTERN_API( OSErr )
  1168. SetDSequenceTimeCode            (ImageSequence             seqID,
  1169.                                  void *                    timeCodeFormat,
  1170.                                  void *                    timeCodeTime)                        FOURWORDINLINE(0x203C, 0x000C, 0x0064, 0xAAA3);
  1171.  
  1172. EXTERN_API( OSErr )
  1173. CDSequenceNewMemory                (ImageSequence             seqID,
  1174.                                  Ptr *                    data,
  1175.                                  Size                     dataSize,
  1176.                                  long                     dataUse,
  1177.                                  ICMMemoryDisposedUPP     memoryGoneProc,
  1178.                                  void *                    refCon)                                FOURWORDINLINE(0x203C, 0x0018, 0x0066, 0xAAA3);
  1179.  
  1180. EXTERN_API( OSErr )
  1181. CDSequenceDisposeMemory            (ImageSequence             seqID,
  1182.                                  Ptr                     data)                                FOURWORDINLINE(0x203C, 0x0008, 0x0067, 0xAAA3);
  1183.  
  1184. EXTERN_API( OSErr )
  1185. CDSequenceNewDataSource            (ImageSequence             seqID,
  1186.                                  ImageSequenceDataSource * sourceID,
  1187.                                  OSType                 sourceType,
  1188.                                  long                     sourceInputNumber,
  1189.                                  Handle                 dataDescription,
  1190.                                  void *                    transferProc,
  1191.                                  void *                    refCon)                                FOURWORDINLINE(0x203C, 0x001C, 0x0068, 0xAAA3);
  1192.  
  1193. EXTERN_API( OSErr )
  1194. CDSequenceDisposeDataSource        (ImageSequenceDataSource  sourceID)                            FOURWORDINLINE(0x203C, 0x0004, 0x0069, 0xAAA3);
  1195.  
  1196. EXTERN_API( OSErr )
  1197. CDSequenceSetSourceData            (ImageSequenceDataSource  sourceID,
  1198.                                  void *                    data,
  1199.                                  long                     dataSize)                            FOURWORDINLINE(0x203C, 0x000C, 0x006A, 0xAAA3);
  1200.  
  1201. EXTERN_API( OSErr )
  1202. CDSequenceChangedSourceData        (ImageSequenceDataSource  sourceID)                            FOURWORDINLINE(0x203C, 0x0004, 0x006B, 0xAAA3);
  1203.  
  1204. EXTERN_API( OSErr )
  1205. CDSequenceSetSourceDataQueue    (ImageSequenceDataSource  sourceID,
  1206.                                  QHdrPtr                 dataQueue)                            FOURWORDINLINE(0x203C, 0x0008, 0x007B, 0xAAA3);
  1207.  
  1208. EXTERN_API( OSErr )
  1209. CDSequenceGetDataSource            (ImageSequence             seqID,
  1210.                                  ImageSequenceDataSource * sourceID,
  1211.                                  OSType                 sourceType,
  1212.                                  long                     sourceInputNumber)                    FOURWORDINLINE(0x203C, 0x0010, 0x007F, 0xAAA3);
  1213.  
  1214. EXTERN_API( OSErr )
  1215. PtInDSequenceData                (ImageSequence             seqID,
  1216.                                  void *                    data,
  1217.                                  Size                     dataSize,
  1218.                                  Point                     where,
  1219.                                  Boolean *                hit)                                FOURWORDINLINE(0x203C, 0x0014, 0x006C, 0xAAA3);
  1220.  
  1221. EXTERN_API( OSErr )
  1222. HitTestDSequenceData            (ImageSequence             seqID,
  1223.                                  void *                    data,
  1224.                                  Size                     dataSize,
  1225.                                  Point                     where,
  1226.                                  long *                    hit,
  1227.                                  long                     hitFlags)                            FOURWORDINLINE(0x203C, 0x0006, 0x0087, 0xAAA3);
  1228.  
  1229. EXTERN_API( OSErr )
  1230. GetGraphicsImporterForFile        (const FSSpec *            theFile,
  1231.                                  ComponentInstance *    gi)                                    FOURWORDINLINE(0x203C, 0x0008, 0x006E, 0xAAA3);
  1232.  
  1233. EXTERN_API( OSErr )
  1234. GetGraphicsImporterForDataRef    (Handle                 dataRef,
  1235.                                  OSType                 dataRefType,
  1236.                                  ComponentInstance *    gi)                                    FOURWORDINLINE(0x203C, 0x000C, 0x0077, 0xAAA3);
  1237.  
  1238.  
  1239. enum {
  1240.     kDontUseValidateToFindGraphicsImporter = 1L << 0
  1241. };
  1242.  
  1243. EXTERN_API( OSErr )
  1244. GetGraphicsImporterForFileWithFlags (const FSSpec *        theFile,
  1245.                                  ComponentInstance *    gi,
  1246.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x000C, 0x0084, 0xAAA3);
  1247.  
  1248. EXTERN_API( OSErr )
  1249. GetGraphicsImporterForDataRefWithFlags (Handle             dataRef,
  1250.                                  OSType                 dataRefType,
  1251.                                  ComponentInstance *    gi,
  1252.                                  long                     flags)                                FOURWORDINLINE(0x203C, 0x0010, 0x0085, 0xAAA3);
  1253.  
  1254. EXTERN_API( OSErr )
  1255. QTGetFileNameExtension            (ConstStrFileNameParam     fileName,
  1256.                                  OSType                 fileType,
  1257.                                  OSType *                extension)                            FOURWORDINLINE(0x203C, 0x000C, 0x0061, 0xAAA3);
  1258.  
  1259. EXTERN_API( OSErr )
  1260. ImageTranscodeSequenceBegin        (ImageTranscodeSequence * its,
  1261.                                  ImageDescriptionHandle  srcDesc,
  1262.                                  OSType                 destType,
  1263.                                  ImageDescriptionHandle * dstDesc,
  1264.                                  void *                    data,
  1265.                                  long                     dataSize)                            FOURWORDINLINE(0x203C, 0x0018, 0x006F, 0xAAA3);
  1266.  
  1267. EXTERN_API( OSErr )
  1268. ImageTranscodeSequenceEnd        (ImageTranscodeSequence  its)                                FOURWORDINLINE(0x203C, 0x0004, 0x0070, 0xAAA3);
  1269.  
  1270. EXTERN_API( OSErr )
  1271. ImageTranscodeFrame                (ImageTranscodeSequence  its,
  1272.                                  void *                    srcData,
  1273.                                  long                     srcDataSize,
  1274.                                  void **                dstData,
  1275.                                  long *                    dstDataSize)                        FOURWORDINLINE(0x203C, 0x0014, 0x0071, 0xAAA3);
  1276.  
  1277. EXTERN_API( OSErr )
  1278. ImageTranscodeDisposeFrameData    (ImageTranscodeSequence  its,
  1279.                                  void *                    dstData)                            FOURWORDINLINE(0x203C, 0x0008, 0x0072, 0xAAA3);
  1280.  
  1281. EXTERN_API( OSErr )
  1282. CDSequenceInvalidate            (ImageSequence             seqID,
  1283.                                  RgnHandle                 invalRgn)                            FOURWORDINLINE(0x203C, 0x0008, 0x0073, 0xAAA3);
  1284.  
  1285. EXTERN_API( OSErr )
  1286. CDSequenceSetTimeBase            (ImageSequence             seqID,
  1287.                                  void *                    base)                                FOURWORDINLINE(0x203C, 0x0008, 0x0079, 0xAAA3);
  1288.  
  1289. EXTERN_API( OSErr )
  1290. ImageFieldSequenceBegin            (ImageFieldSequence *    ifs,
  1291.                                  ImageDescriptionHandle  desc1,
  1292.                                  ImageDescriptionHandle  desc2,
  1293.                                  ImageDescriptionHandle  descOut)                            FOURWORDINLINE(0x203C, 0x0010, 0x006D, 0xAAA3);
  1294.  
  1295. EXTERN_API( OSErr )
  1296. ImageFieldSequenceExtractCombine (ImageFieldSequence     ifs,
  1297.                                  long                     fieldFlags,
  1298.                                  void *                    data1,
  1299.                                  long                     dataSize1,
  1300.                                  void *                    data2,
  1301.                                  long                     dataSize2,
  1302.                                  void *                    outputData,
  1303.                                  long *                    outDataSize)                        FOURWORDINLINE(0x203C, 0x0020, 0x0075, 0xAAA3);
  1304.  
  1305. EXTERN_API( OSErr )
  1306. ImageFieldSequenceEnd            (ImageFieldSequence     ifs)                                FOURWORDINLINE(0x203C, 0x0004, 0x0076, 0xAAA3);
  1307.  
  1308.  
  1309. enum {
  1310.     kICMTempThenAppMemory        = 1L << 12,
  1311.     kICMAppThenTempMemory        = 1L << 13
  1312. };
  1313.  
  1314. EXTERN_API( OSErr )
  1315. QTNewGWorld                        (GWorldPtr *            offscreenGWorld,
  1316.                                  OSType                 PixelFormat,
  1317.                                  const Rect *            boundsRect,
  1318.                                  CTabHandle             cTable,
  1319.                                  GDHandle                 aGDevice,
  1320.                                  GWorldFlags             flags)                                FOURWORDINLINE(0x203C, 0x0018, 0x0080, 0xAAA3);
  1321.  
  1322. EXTERN_API( GWorldFlags )
  1323. QTUpdateGWorld                    (GWorldPtr *            offscreenGWorld,
  1324.                                  OSType                 PixelFormat,
  1325.                                  const Rect *            boundsRect,
  1326.                                  CTabHandle             cTable,
  1327.                                  GDHandle                 aGDevice,
  1328.                                  GWorldFlags             flags)                                FOURWORDINLINE(0x203C, 0x0018, 0x0081, 0xAAA3);
  1329.  
  1330. EXTERN_API( OSErr )
  1331. MakeImageDescriptionForPixMap    (PixMapHandle             pixmap,
  1332.                                  ImageDescriptionHandle * idh)                                FOURWORDINLINE(0x203C, 0x0008, 0x007A, 0xAAA3);
  1333.  
  1334. EXTERN_API( short )
  1335. QTGetPixelSize                    (OSType                 PixelFormat)                        FOURWORDINLINE(0x203C, 0x0004, 0x0086, 0xAAA3);
  1336.  
  1337.  
  1338.  
  1339.  
  1340. enum {
  1341.     identityMatrixType            = 0x00,                            /* result if matrix is identity */
  1342.     translateMatrixType            = 0x01,                            /* result if matrix translates */
  1343.     scaleMatrixType                = 0x02,                            /* result if matrix scales */
  1344.     scaleTranslateMatrixType    = 0x03,                            /* result if matrix scales and translates */
  1345.     linearMatrixType            = 0x04,                            /* result if matrix is general 2 x 2 */
  1346.     linearTranslateMatrixType    = 0x05,                            /* result if matrix is general 2 x 2 and translates */
  1347.     perspectiveMatrixType        = 0x06                            /* result if matrix is general 3 x 3 */
  1348. };
  1349.  
  1350.  
  1351. typedef unsigned short                     MatrixFlags;
  1352. EXTERN_API( short )
  1353. GetMatrixType                    (const MatrixRecord *    m)                                    TWOWORDINLINE(0x7014, 0xABC2);
  1354.  
  1355. EXTERN_API( void )
  1356. CopyMatrix                        (const MatrixRecord *    m1,
  1357.                                  MatrixRecord *            m2)                                    TWOWORDINLINE(0x7020, 0xABC2);
  1358.  
  1359. EXTERN_API( Boolean )
  1360. EqualMatrix                        (const MatrixRecord *    m1,
  1361.                                  const MatrixRecord *    m2)                                    TWOWORDINLINE(0x7021, 0xABC2);
  1362.  
  1363. EXTERN_API( void )
  1364. SetIdentityMatrix                (MatrixRecord *            matrix)                                TWOWORDINLINE(0x7015, 0xABC2);
  1365.  
  1366. EXTERN_API( void )
  1367. TranslateMatrix                    (MatrixRecord *            m,
  1368.                                  Fixed                     deltaH,
  1369.                                  Fixed                     deltaV)                                TWOWORDINLINE(0x7019, 0xABC2);
  1370.  
  1371. EXTERN_API( void )
  1372. RotateMatrix                    (MatrixRecord *            m,
  1373.                                  Fixed                     degrees,
  1374.                                  Fixed                     aboutX,
  1375.                                  Fixed                     aboutY)                                TWOWORDINLINE(0x7016, 0xABC2);
  1376.  
  1377. EXTERN_API( void )
  1378. ScaleMatrix                        (MatrixRecord *            m,
  1379.                                  Fixed                     scaleX,
  1380.                                  Fixed                     scaleY,
  1381.                                  Fixed                     aboutX,
  1382.                                  Fixed                     aboutY)                                TWOWORDINLINE(0x7017, 0xABC2);
  1383.  
  1384. EXTERN_API( void )
  1385. SkewMatrix                        (MatrixRecord *            m,
  1386.                                  Fixed                     skewX,
  1387.                                  Fixed                     skewY,
  1388.                                  Fixed                     aboutX,
  1389.                                  Fixed                     aboutY)                                TWOWORDINLINE(0x7018, 0xABC2);
  1390.  
  1391. EXTERN_API( OSErr )
  1392. TransformFixedPoints            (const MatrixRecord *    m,
  1393.                                  FixedPoint *            fpt,
  1394.                                  long                     count)                                TWOWORDINLINE(0x7022, 0xABC2);
  1395.  
  1396. EXTERN_API( OSErr )
  1397. TransformPoints                    (const MatrixRecord *    mp,
  1398.                                  Point *                pt1,
  1399.                                  long                     count)                                TWOWORDINLINE(0x7023, 0xABC2);
  1400.  
  1401. EXTERN_API( Boolean )
  1402. TransformFixedRect                (const MatrixRecord *    m,
  1403.                                  FixedRect *            fr,
  1404.                                  FixedPoint *            fpp)                                TWOWORDINLINE(0x7024, 0xABC2);
  1405.  
  1406. EXTERN_API( Boolean )
  1407. TransformRect                    (const MatrixRecord *    m,
  1408.                                  Rect *                    r,
  1409.                                  FixedPoint *            fpp)                                TWOWORDINLINE(0x7025, 0xABC2);
  1410.  
  1411. EXTERN_API( Boolean )
  1412. InverseMatrix                    (const MatrixRecord *    m,
  1413.                                  MatrixRecord *            im)                                    TWOWORDINLINE(0x701C, 0xABC2);
  1414.  
  1415. EXTERN_API( void )
  1416. ConcatMatrix                    (const MatrixRecord *    a,
  1417.                                  MatrixRecord *            b)                                    TWOWORDINLINE(0x701B, 0xABC2);
  1418.  
  1419. EXTERN_API( void )
  1420. RectMatrix                        (MatrixRecord *            matrix,
  1421.                                  const Rect *            srcRect,
  1422.                                  const Rect *            dstRect)                            TWOWORDINLINE(0x701E, 0xABC2);
  1423.  
  1424. EXTERN_API( void )
  1425. MapMatrix                        (MatrixRecord *            matrix,
  1426.                                  const Rect *            fromRect,
  1427.                                  const Rect *            toRect)                                TWOWORDINLINE(0x701D, 0xABC2);
  1428.  
  1429.  
  1430.  
  1431.  
  1432.  
  1433.  
  1434.  
  1435. EXTERN_API( void )
  1436. CompAdd                            (wide *                    src,
  1437.                                  wide *                    dst)                                TWOWORDINLINE(0x7001, 0xABC2);
  1438.  
  1439. EXTERN_API( void )
  1440. CompSub                            (wide *                    src,
  1441.                                  wide *                    dst)                                TWOWORDINLINE(0x7002, 0xABC2);
  1442.  
  1443. EXTERN_API( void )
  1444. CompNeg                            (wide *                    dst)                                TWOWORDINLINE(0x7003, 0xABC2);
  1445.  
  1446. EXTERN_API( void )
  1447. CompShift                        (wide *                    src,
  1448.                                  short                     shift)                                TWOWORDINLINE(0x7004, 0xABC2);
  1449.  
  1450. EXTERN_API( void )
  1451. CompMul                            (long                     src1,
  1452.                                  long                     src2,
  1453.                                  wide *                    dst)                                TWOWORDINLINE(0x7005, 0xABC2);
  1454.  
  1455. EXTERN_API( long )
  1456. CompDiv                            (wide *                    numerator,
  1457.                                  long                     denominator,
  1458.                                  long *                    remainder)                            TWOWORDINLINE(0x7006, 0xABC2);
  1459.  
  1460. EXTERN_API( void )
  1461. CompFixMul                        (wide *                    compSrc,
  1462.                                  Fixed                     fixSrc,
  1463.                                  wide *                    compDst)                            TWOWORDINLINE(0x7007, 0xABC2);
  1464.  
  1465. EXTERN_API( void )
  1466. CompMulDiv                        (wide *                    co,
  1467.                                  long                     mul,
  1468.                                  long                     divisor)                            TWOWORDINLINE(0x7008, 0xABC2);
  1469.  
  1470. EXTERN_API( void )
  1471. CompMulDivTrunc                    (wide *                    co,
  1472.                                  long                     mul,
  1473.                                  long                     divisor,
  1474.                                  long *                    remainder)                            TWOWORDINLINE(0x700C, 0xABC2);
  1475.  
  1476. EXTERN_API( long )
  1477. CompCompare                        (wide *                    a,
  1478.                                  wide *                    minusb)                                TWOWORDINLINE(0x7009, 0xABC2);
  1479.  
  1480. EXTERN_API( unsigned long )
  1481. CompSquareRoot                    (const wide *            src)                                TWOWORDINLINE(0x7011, 0xABC2);
  1482.  
  1483. EXTERN_API( Fixed )
  1484. FixMulDiv                        (Fixed                     src,
  1485.                                  Fixed                     mul,
  1486.                                  Fixed                     divisor)                            TWOWORDINLINE(0x700A, 0xABC2);
  1487.  
  1488. EXTERN_API( Fixed )
  1489. UnsignedFixMulDiv                (Fixed                     src,
  1490.                                  Fixed                     mul,
  1491.                                  Fixed                     divisor)                            TWOWORDINLINE(0x700D, 0xABC2);
  1492.  
  1493. EXTERN_API( Fract )
  1494. FracSinCos                        (Fixed                     degree,
  1495.                                  Fract *                cosOut)                                TWOWORDINLINE(0x700B, 0xABC2);
  1496.  
  1497. EXTERN_API( Fixed )
  1498. FixExp2                            (Fixed                     src)                                TWOWORDINLINE(0x700E, 0xABC2);
  1499.  
  1500. EXTERN_API( Fixed )
  1501. FixLog2                            (Fixed                     src)                                TWOWORDINLINE(0x700F, 0xABC2);
  1502.  
  1503. EXTERN_API( Fixed )
  1504. FixPow                            (Fixed                     base,
  1505.                                  Fixed                     exp)                                TWOWORDINLINE(0x7010, 0xABC2);
  1506.  
  1507.  
  1508.  
  1509.  
  1510. typedef ComponentInstance                 GraphicsImportComponent;
  1511.  
  1512. enum {
  1513.     GraphicsImporterComponentType = FOUR_CHAR_CODE('grip')
  1514. };
  1515.  
  1516.  
  1517. enum {
  1518.     graphicsImporterUsesImageDecompressor = 1L << 23
  1519. };
  1520.  
  1521.  
  1522. enum {
  1523.     quickTimeImageFileImageDescriptionAtom = FOUR_CHAR_CODE('idsc'),
  1524.     quickTimeImageFileImageDataAtom = FOUR_CHAR_CODE('idat'),
  1525.     quickTimeImageFileMetaDataAtom = FOUR_CHAR_CODE('meta')
  1526. };
  1527.  
  1528.  
  1529. enum {
  1530.     graphicsImporterDrawsAllPixels = 0,
  1531.     graphicsImporterDoesntDrawAllPixels = 1,
  1532.     graphicsImporterDontKnowIfDrawAllPixels = 2
  1533. };
  1534.  
  1535.  
  1536. enum {
  1537.     kGraphicsExportGroup        = FOUR_CHAR_CODE('expo'),
  1538.     kGraphicsExportFileType        = FOUR_CHAR_CODE('ftyp'),
  1539.     kGraphicsExportMIMEType        = FOUR_CHAR_CODE('mime'),
  1540.     kGraphicsExportExtension    = FOUR_CHAR_CODE('ext '),
  1541.     kGraphicsExportDescription    = FOUR_CHAR_CODE('desc')
  1542. };
  1543.  
  1544.  
  1545. EXTERN_API( ComponentResult )
  1546. GraphicsImportSetDataReference    (GraphicsImportComponent  ci,
  1547.                                  Handle                 dataRef,
  1548.                                  OSType                 dataReType)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0001, 0x7000, 0xA82A);
  1549.  
  1550. EXTERN_API( ComponentResult )
  1551. GraphicsImportGetDataReference    (GraphicsImportComponent  ci,
  1552.                                  Handle *                dataRef,
  1553.                                  OSType *                dataReType)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0002, 0x7000, 0xA82A);
  1554.  
  1555. EXTERN_API( ComponentResult )
  1556. GraphicsImportSetDataFile        (GraphicsImportComponent  ci,
  1557.                                  const FSSpec *            theFile)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0003, 0x7000, 0xA82A);
  1558.  
  1559. EXTERN_API( ComponentResult )
  1560. GraphicsImportGetDataFile        (GraphicsImportComponent  ci,
  1561.                                  FSSpec *                theFile)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0004, 0x7000, 0xA82A);
  1562.  
  1563. EXTERN_API( ComponentResult )
  1564. GraphicsImportSetDataHandle        (GraphicsImportComponent  ci,
  1565.                                  Handle                 h)                                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0005, 0x7000, 0xA82A);
  1566.  
  1567. EXTERN_API( ComponentResult )
  1568. GraphicsImportGetDataHandle        (GraphicsImportComponent  ci,
  1569.                                  Handle *                h)                                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0006, 0x7000, 0xA82A);
  1570.  
  1571. EXTERN_API( ComponentResult )
  1572. GraphicsImportGetImageDescription (GraphicsImportComponent  ci,
  1573.                                  ImageDescriptionHandle * desc)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0007, 0x7000, 0xA82A);
  1574.  
  1575. EXTERN_API( ComponentResult )
  1576. GraphicsImportGetDataOffsetAndSize (GraphicsImportComponent  ci,
  1577.                                  unsigned long *        offset,
  1578.                                  unsigned long *        size)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x0008, 0x7000, 0xA82A);
  1579.  
  1580. EXTERN_API( ComponentResult )
  1581. GraphicsImportReadData            (GraphicsImportComponent  ci,
  1582.                                  void *                    dataPtr,
  1583.                                  unsigned long             dataOffset,
  1584.                                  unsigned long             dataSize)                            FIVEWORDINLINE(0x2F3C, 0x000C, 0x0009, 0x7000, 0xA82A);
  1585.  
  1586. EXTERN_API( ComponentResult )
  1587. GraphicsImportSetClip            (GraphicsImportComponent  ci,
  1588.                                  RgnHandle                 clipRgn)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000A, 0x7000, 0xA82A);
  1589.  
  1590. EXTERN_API( ComponentResult )
  1591. GraphicsImportGetClip            (GraphicsImportComponent  ci,
  1592.                                  RgnHandle *            clipRgn)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000B, 0x7000, 0xA82A);
  1593.  
  1594. EXTERN_API( ComponentResult )
  1595. GraphicsImportSetSourceRect        (GraphicsImportComponent  ci,
  1596.                                  const Rect *            sourceRect)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000C, 0x7000, 0xA82A);
  1597.  
  1598. EXTERN_API( ComponentResult )
  1599. GraphicsImportGetSourceRect        (GraphicsImportComponent  ci,
  1600.                                  Rect *                    sourceRect)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x000D, 0x7000, 0xA82A);
  1601.  
  1602. EXTERN_API( ComponentResult )
  1603. GraphicsImportGetNaturalBounds    (GraphicsImportComponent  ci,
  1604.                                  Rect *                    naturalBounds)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x000E, 0x7000, 0xA82A);
  1605.  
  1606. EXTERN_API( ComponentResult )
  1607. GraphicsImportDraw                (GraphicsImportComponent  ci)                                FIVEWORDINLINE(0x2F3C, 0x0000, 0x000F, 0x7000, 0xA82A);
  1608.  
  1609. EXTERN_API( ComponentResult )
  1610. GraphicsImportSetGWorld            (GraphicsImportComponent  ci,
  1611.                                  CGrafPtr                 port,
  1612.                                  GDHandle                 gd)                                    FIVEWORDINLINE(0x2F3C, 0x0008, 0x0010, 0x7000, 0xA82A);
  1613.  
  1614. EXTERN_API( ComponentResult )
  1615. GraphicsImportGetGWorld            (GraphicsImportComponent  ci,
  1616.                                  CGrafPtr *                port,
  1617.                                  GDHandle *                gd)                                    FIVEWORDINLINE(0x2F3C, 0x0008, 0x0011, 0x7000, 0xA82A);
  1618.  
  1619. EXTERN_API( ComponentResult )
  1620. GraphicsImportSetMatrix            (GraphicsImportComponent  ci,
  1621.                                  const MatrixRecord *    matrix)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0012, 0x7000, 0xA82A);
  1622.  
  1623. EXTERN_API( ComponentResult )
  1624. GraphicsImportGetMatrix            (GraphicsImportComponent  ci,
  1625.                                  MatrixRecord *            matrix)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0013, 0x7000, 0xA82A);
  1626.  
  1627. EXTERN_API( ComponentResult )
  1628. GraphicsImportSetBoundsRect        (GraphicsImportComponent  ci,
  1629.                                  const Rect *            bounds)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0014, 0x7000, 0xA82A);
  1630.  
  1631. EXTERN_API( ComponentResult )
  1632. GraphicsImportGetBoundsRect        (GraphicsImportComponent  ci,
  1633.                                  Rect *                    bounds)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x0015, 0x7000, 0xA82A);
  1634.  
  1635. EXTERN_API( ComponentResult )
  1636. GraphicsImportSaveAsPicture        (GraphicsImportComponent  ci,
  1637.                                  const FSSpec *            fss,
  1638.                                  ScriptCode             scriptTag)                            FIVEWORDINLINE(0x2F3C, 0x0006, 0x0016, 0x7000, 0xA82A);
  1639.  
  1640. EXTERN_API( ComponentResult )
  1641. GraphicsImportSetGraphicsMode    (GraphicsImportComponent  ci,
  1642.                                  long                     graphicsMode,
  1643.                                  const RGBColor *        opColor)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0017, 0x7000, 0xA82A);
  1644.  
  1645. EXTERN_API( ComponentResult )
  1646. GraphicsImportGetGraphicsMode    (GraphicsImportComponent  ci,
  1647.                                  long *                    graphicsMode,
  1648.                                  RGBColor *                opColor)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0018, 0x7000, 0xA82A);
  1649.  
  1650. EXTERN_API( ComponentResult )
  1651. GraphicsImportSetQuality        (GraphicsImportComponent  ci,
  1652.                                  CodecQ                 quality)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0019, 0x7000, 0xA82A);
  1653.  
  1654. EXTERN_API( ComponentResult )
  1655. GraphicsImportGetQuality        (GraphicsImportComponent  ci,
  1656.                                  CodecQ *                quality)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x001A, 0x7000, 0xA82A);
  1657.  
  1658. EXTERN_API( ComponentResult )
  1659. GraphicsImportSaveAsQuickTimeImageFile (GraphicsImportComponent  ci,
  1660.                                  const FSSpec *            fss,
  1661.                                  ScriptCode             scriptTag)                            FIVEWORDINLINE(0x2F3C, 0x0006, 0x001B, 0x7000, 0xA82A);
  1662.  
  1663. EXTERN_API( ComponentResult )
  1664. GraphicsImportSetDataReferenceOffsetAndLimit (GraphicsImportComponent  ci,
  1665.                                  unsigned long             offset,
  1666.                                  unsigned long             limit)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x001C, 0x7000, 0xA82A);
  1667.  
  1668. EXTERN_API( ComponentResult )
  1669. GraphicsImportGetDataReferenceOffsetAndLimit (GraphicsImportComponent  ci,
  1670.                                  unsigned long *        offset,
  1671.                                  unsigned long *        limit)                                FIVEWORDINLINE(0x2F3C, 0x0008, 0x001D, 0x7000, 0xA82A);
  1672.  
  1673. EXTERN_API( ComponentResult )
  1674. GraphicsImportGetAliasedDataReference (GraphicsImportComponent  ci,
  1675.                                  Handle *                dataRef,
  1676.                                  OSType *                dataRefType)                        FIVEWORDINLINE(0x2F3C, 0x0008, 0x001E, 0x7000, 0xA82A);
  1677.  
  1678. EXTERN_API( ComponentResult )
  1679. GraphicsImportValidate            (GraphicsImportComponent  ci,
  1680.                                  Boolean *                valid)                                FIVEWORDINLINE(0x2F3C, 0x0004, 0x001F, 0x7000, 0xA82A);
  1681.  
  1682. EXTERN_API( ComponentResult )
  1683. GraphicsImportGetMetaData        (GraphicsImportComponent  ci,
  1684.                                  void *                    userData)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0020, 0x7000, 0xA82A);
  1685.  
  1686. EXTERN_API( ComponentResult )
  1687. GraphicsImportGetMIMETypeList    (GraphicsImportComponent  ci,
  1688.                                  void *                    qtAtomContainerPtr)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0021, 0x7000, 0xA82A);
  1689.  
  1690. EXTERN_API( ComponentResult )
  1691. GraphicsImportDoesDrawAllPixels    (GraphicsImportComponent  ci,
  1692.                                  short *                drawsAllPixels)                        FIVEWORDINLINE(0x2F3C, 0x0004, 0x0022, 0x7000, 0xA82A);
  1693.  
  1694. EXTERN_API( ComponentResult )
  1695. GraphicsImportGetAsPicture        (GraphicsImportComponent  ci,
  1696.                                  PicHandle *            picture)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0023, 0x7000, 0xA82A);
  1697.  
  1698. EXTERN_API( ComponentResult )
  1699. GraphicsImportExportImageFile    (GraphicsImportComponent  ci,
  1700.                                  OSType                 fileType,
  1701.                                  OSType                 fileCreator,
  1702.                                  const FSSpec *            fss,
  1703.                                  ScriptCode             scriptTag)                            FIVEWORDINLINE(0x2F3C, 0x000E, 0x0024, 0x7000, 0xA82A);
  1704.  
  1705. EXTERN_API( ComponentResult )
  1706. GraphicsImportGetExportImageTypeList (GraphicsImportComponent  ci,
  1707.                                  void *                    qtAtomContainerPtr)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0025, 0x7000, 0xA82A);
  1708.  
  1709. EXTERN_API( ComponentResult )
  1710. GraphicsImportDoExportImageFileDialog (GraphicsImportComponent  ci,
  1711.                                  const FSSpec *            inDefaultSpec,
  1712.                                  StringPtr                 prompt,
  1713.                                  ModalFilterYDUPP         filterProc,
  1714.                                  OSType *                outExportedType,
  1715.                                  FSSpec *                outExportedSpec,
  1716.                                  ScriptCode *            outScriptTag)                        FIVEWORDINLINE(0x2F3C, 0x0018, 0x0026, 0x7000, 0xA82A);
  1717.  
  1718. EXTERN_API( ComponentResult )
  1719. GraphicsImportGetExportSettingsAsAtomContainer (GraphicsImportComponent  ci,
  1720.                                  void *                    qtAtomContainerPtr)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0027, 0x7000, 0xA82A);
  1721.  
  1722. EXTERN_API( ComponentResult )
  1723. GraphicsImportSetExportSettingsFromAtomContainer (GraphicsImportComponent  ci,
  1724.                                  void *                    qtAtomContainer)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0028, 0x7000, 0xA82A);
  1725.  
  1726. EXTERN_API( ComponentResult )
  1727. GraphicsImportSetProgressProc    (GraphicsImportComponent  ci,
  1728.                                  ICMProgressProcRecordPtr  progressProc)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x0029, 0x7000, 0xA82A);
  1729.  
  1730. EXTERN_API( ComponentResult )
  1731. GraphicsImportGetProgressProc    (GraphicsImportComponent  ci,
  1732.                                  ICMProgressProcRecordPtr  progressProc)                    FIVEWORDINLINE(0x2F3C, 0x0004, 0x002A, 0x7000, 0xA82A);
  1733.  
  1734.  
  1735. typedef ComponentInstance                 ImageTranscoderComponent;
  1736.  
  1737. enum {
  1738.     ImageTranscodererComponentType = FOUR_CHAR_CODE('imtc')
  1739. };
  1740.  
  1741.  
  1742. EXTERN_API( ComponentResult )
  1743. ImageTranscoderBeginSequence    (ImageTranscoderComponent  itc,
  1744.                                  ImageDescriptionHandle  srcDesc,
  1745.                                  ImageDescriptionHandle * dstDesc,
  1746.                                  void *                    data,
  1747.                                  long                     dataSize)                            FIVEWORDINLINE(0x2F3C, 0x0010, 0x0001, 0x7000, 0xA82A);
  1748.  
  1749. EXTERN_API( ComponentResult )
  1750. ImageTranscoderConvert            (ImageTranscoderComponent  itc,
  1751.                                  void *                    srcData,
  1752.                                  long                     srcDataSize,
  1753.                                  void **                dstData,
  1754.                                  long *                    dstDataSize)                        FIVEWORDINLINE(0x2F3C, 0x0010, 0x0002, 0x7000, 0xA82A);
  1755.  
  1756. EXTERN_API( ComponentResult )
  1757. ImageTranscoderDisposeData        (ImageTranscoderComponent  itc,
  1758.                                  void *                    dstData)                            FIVEWORDINLINE(0x2F3C, 0x0004, 0x0003, 0x7000, 0xA82A);
  1759.  
  1760. EXTERN_API( ComponentResult )
  1761. ImageTranscoderEndSequence        (ImageTranscoderComponent  itc)                                FIVEWORDINLINE(0x2F3C, 0x0000, 0x0004, 0x7000, 0xA82A);
  1762.  
  1763. /* UPP call backs */
  1764.  
  1765. /* selectors for component calls */
  1766. enum {
  1767.     kGraphicsImportSetDataReferenceSelect            = 0x0001,
  1768.     kGraphicsImportGetDataReferenceSelect            = 0x0002,
  1769.     kGraphicsImportSetDataFileSelect                = 0x0003,
  1770.     kGraphicsImportGetDataFileSelect                = 0x0004,
  1771.     kGraphicsImportSetDataHandleSelect                = 0x0005,
  1772.     kGraphicsImportGetDataHandleSelect                = 0x0006,
  1773.     kGraphicsImportGetImageDescriptionSelect        = 0x0007,
  1774.     kGraphicsImportGetDataOffsetAndSizeSelect        = 0x0008,
  1775.     kGraphicsImportReadDataSelect                    = 0x0009,
  1776.     kGraphicsImportSetClipSelect                    = 0x000A,
  1777.     kGraphicsImportGetClipSelect                    = 0x000B,
  1778.     kGraphicsImportSetSourceRectSelect                = 0x000C,
  1779.     kGraphicsImportGetSourceRectSelect                = 0x000D,
  1780.     kGraphicsImportGetNaturalBoundsSelect            = 0x000E,
  1781.     kGraphicsImportDrawSelect                        = 0x000F,
  1782.     kGraphicsImportSetGWorldSelect                    = 0x0010,
  1783.     kGraphicsImportGetGWorldSelect                    = 0x0011,
  1784.     kGraphicsImportSetMatrixSelect                    = 0x0012,
  1785.     kGraphicsImportGetMatrixSelect                    = 0x0013,
  1786.     kGraphicsImportSetBoundsRectSelect                = 0x0014,
  1787.     kGraphicsImportGetBoundsRectSelect                = 0x0015,
  1788.     kGraphicsImportSaveAsPictureSelect                = 0x0016,
  1789.     kGraphicsImportSetGraphicsModeSelect            = 0x0017,
  1790.     kGraphicsImportGetGraphicsModeSelect            = 0x0018,
  1791.     kGraphicsImportSetQualitySelect                    = 0x0019,
  1792.     kGraphicsImportGetQualitySelect                    = 0x001A,
  1793.     kGraphicsImportSaveAsQuickTimeImageFileSelect    = 0x001B,
  1794.     kGraphicsImportSetDataReferenceOffsetAndLimitSelect = 0x001C,
  1795.     kGraphicsImportGetDataReferenceOffsetAndLimitSelect = 0x001D,
  1796.     kGraphicsImportGetAliasedDataReferenceSelect    = 0x001E,
  1797.     kGraphicsImportValidateSelect                    = 0x001F,
  1798.     kGraphicsImportGetMetaDataSelect                = 0x0020,
  1799.     kGraphicsImportGetMIMETypeListSelect            = 0x0021,
  1800.     kGraphicsImportDoesDrawAllPixelsSelect            = 0x0022,
  1801.     kGraphicsImportGetAsPictureSelect                = 0x0023,
  1802.     kGraphicsImportExportImageFileSelect            = 0x0024,
  1803.     kGraphicsImportGetExportImageTypeListSelect        = 0x0025,
  1804.     kGraphicsImportDoExportImageFileDialogSelect    = 0x0026,
  1805.     kGraphicsImportGetExportSettingsAsAtomContainerSelect = 0x0027,
  1806.     kGraphicsImportSetExportSettingsFromAtomContainerSelect = 0x0028,
  1807.     kGraphicsImportSetProgressProcSelect            = 0x0029,
  1808.     kGraphicsImportGetProgressProcSelect            = 0x002A,
  1809.     kImageTranscoderBeginSequenceSelect                = 0x0001,
  1810.     kImageTranscoderConvertSelect                    = 0x0002,
  1811.     kImageTranscoderDisposeDataSelect                = 0x0003,
  1812.     kImageTranscoderEndSequenceSelect                = 0x0004
  1813. };
  1814.  
  1815. #if PRAGMA_STRUCT_ALIGN
  1816.     #pragma options align=reset
  1817. #elif PRAGMA_STRUCT_PACKPUSH
  1818.     #pragma pack(pop)
  1819. #elif PRAGMA_STRUCT_PACK
  1820.     #pragma pack()
  1821. #endif
  1822.  
  1823. #ifdef PRAGMA_IMPORT_OFF
  1824. #pragma import off
  1825. #elif PRAGMA_IMPORT
  1826. #pragma import reset
  1827. #endif
  1828.  
  1829. #ifdef __cplusplus
  1830. }
  1831. #endif
  1832.  
  1833. #endif /* __IMAGECOMPRESSION__ */
  1834.  
  1835.